بيان المشكلة
Write a C program to perform a linear search on a 1D array. Input the size n, the array elements, and a target value key. If the key is present, print "FOUND at index i" (where i is the 0-based index of the first occurrence). If not found, print "NOT FOUND".
Example 1
Input:
5 10 20 30 40 50 30
Output:
FOUND at index 2
Example 2
Input:
5 10 20 30 40 50 99
Output:
NOT FOUND