Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a program that accepts an array of numbers and a
number, and return a string “Yes” if
the number is found in the array, “No” if the number is not
found in the array.

Answer Posted / surabhi

void main()
{
int num,i=0,f=0;
int n[]={20,30,40,50};
printf("\n enter no:");
scanf("%d",&num);
for(;i<4;)
{
if(num==n[i++])
{
printf("\n YES");
f=1;
break;
}
}
if(f==0)
printf("\n NO");
getch();
}

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the differences between vb.net and c#, related to oops concepts?

889


Explain and brief about rapid application development tool?

951


What is the Advantage of vb.net over vb

945


What is the strong name in .net assembly?

950


Is vb.net a programming language?

921


Explain how can we remove handlers at run time?

950


What is code access security?

1138


Explain internal keyword in .net framework?

935


what is common language specification?

920


Name some different types of control?

928


Explain code security?

863


How would you implement inheritance using vb.net?

866


Observations between vb.net and vc#.net?

998


What are the features present in vb 2005?

978


What is the difference between vb 6 and vb.net?

1038