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.

Answers were Sorted based on User's Feedback



Write a program that accepts an array of numbers and a number, and return a string “Yes” if th..

Answer / lince

Dim num() As Integer = {5, 3, 6, 7, 1}
Public Function Find(ByVal sNum As Integer) As String
Dim i As Integer = 0
For i = 0 To num.Count - 1
If (sNum = num(i)) Then
Return "Yes"
End If
Next
Return "No"
End Function

Is This Answer Correct ?    1 Yes 0 No

Write a program that accepts an array of numbers and a number, and return a string “Yes” if th..

Answer / 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

More VB.NET Interview Questions

What is the Difference between Web User Control and Web Custom Control?

6 Answers   Benchmark,


Regarding Types of compatability in VB and their usage ?

1 Answers   Satyam,


Can you please explain the difference between int and int32?

0 Answers  


What’s the difference between private and shared assembly?

0 Answers  


How does you call and execute a SP in .NET?

2 Answers  


How to store decimal data in .net?

0 Answers  


Explain about globalization?

0 Answers  


What is "Polymorphism" and what are Polymorphism in VB.Net?

2 Answers  


Explain about the feature anonymous type?

0 Answers  


if user enters 1 or 2 or any other number in digit format in next textbox it should show the answer in word reading like if enters 12 answer should be twelve

4 Answers  


How to view an assembly?

0 Answers  


How do you use two datareaders at the same time in a vb.net windows application ?

0 Answers  


Categories