cud any one tell me what is the problem in this program
#include<iostre am.h>
#include<conio. h>
#include<stdlib .h>
int binarysearch(vo id)
int linearsearch(vo id)
class search
{
private:
int[20],beg,mid,end,,i ,j,n,item;
public:
void input()
{
cout<<"\n how much element you want to enter";
cin>>n;
cout<<"\n enter the elements";
for(i=0;i<n;i++ )
cin>>a[i];
cout<<"\n enter the element to be searched";
cin>>item;
beg=0;
end=n-1;
}
int binarysearch()
{
mid=(beg+end)/2;
while((beg<end) &&a[mid]!=item))
{
if (item>a[mid])
beg=mid+1;
mid=(beg+end)/2;
}
}
if (item==a[mid])
cout<<"item"<<i tem<<"is found at location"<<mid+ 1<<"position";
else
cout<<"item is not found";
}
int linearsearch()
{
int flag;
for(i=0;i<n;i++ )
{
if(a[i]==item)
{
flag=1;
cout<<"item"<<i tem<<"found at location"<<i+1;
break;
}
flag=0;
}
if(!flag)
cout<<"item not found";
}
};
void main()
{
clrscr();
search obj;
int choice;
do
{
cout<<"\n 1. linear search";
cout<<"\n 2. binary search";
cout<<"\n 3. exit";
cout<<"\n enter your choice";
cin>>choice;
switch(choice)
{
case 1:
obj.input();
obj.linearsearc h();
break;
case 2:
obj.input();
obj.binarysearc h();
break;
case 3:
exit(1);
}
}
while(choice!=3 );
getch();
}