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...

a=0;
while(a<5)
printf("%d\n",a++);
how many times does the loop occurs?
a.infinite
b.5
c.4
d.6

Answer Posted / bharath kumar

Hello,

The answer is b.

a=0+1=1
a=1+1=2
a=2+1=3
a=3+1=4
a=4+1=5

While a variable is storing the 5 result a is nither less
then are equal to 5 hence the application will come out of
the loop.So while loop had run 5 times.

Is This Answer Correct ?    28 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain modulus operator. What are the restrictions of a modulus operator?

970


How can I rethow can I return a sequence of random numbers which dont repeat at all?

1147


What does stand for?

1045


Explain what is the difference between the expression '++a' and 'a++'?

1153


What are derived data types in c?

1009


What are the primitive data types in c?

1007


How to write a code for reverse of string without using string functions?

2075


we called a function and passed something do it we have always passed the "values" of variables to the called function. such functions calles are called a) calls by reference b) calls by value c) calls by zero d) none of the above

1103


What are header files in c programming?

1075


Difference between goto, long jmp() and setjmp()?

1124


What header files do I need in order to define the standard library functions I use?

998


What is pointer & why it is used?

1062


What is the difference between a string copy (strcpy) and a memory copy (memcpy)? When should each be used?

1051


Create a structure to specify data on students given below: Roll number, Name, Department, Course, Year of joining Assume that there are not more than 450 students in the college. 1.write a function to print names of all students who joined in a particular year 2.write a function to print the data of a student whose roll number is given

3013


Explain what happens if you free a pointer twice?

1016