#include<stdio.h>
#include<conio.h>
#include<iostream.h>
void main()
{
int n,a[100];
clrscr();
cout<<"How many numbers, you input in array : ";
cin>>n;
for(int i=0;i<n;i++)
{
printf("\na[%d] = ",i+1);
scanf("%d",&a[i]);
}
int p;
cout<<"\nEnter any number to search : ";
cin>>p;
int f=0;
for(i=0;i<n;i++)
if(a[i]==p)
f=1;
if(f==1)
cout<<"\n"<<p<<" is found in the array....";
else
cout<<"\n"<<p<<" is not found in the array....";
getch();
}
///////////////////////////////////////////////////////////////////////////
Copy & paste this code in your TC & run, then you will get output.......
If you have any problem please comment below.........