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

What is the output of the program given below

#include<stdio.h>
main()
{
char i=0;
for(;i>=0;i++) ;
printf("%d\n",i);
}

Answer Posted / akash dhal

initialized with 0
in for loop ist time condition satisfied so print 0,like
this 127 will be printed .as it is a signed no. so 127+1 is
-128 so condition false come out of the loop.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is it fine to write void main () or main () in c?

982


What is type qualifiers?

1091


Write a function that will take in a phone number and output all possible alphabetical combinations

1013


write a program to find out prime number using sieve case?

2055


What could possibly be the problem if a valid function name such as tolower() is being reported by the C compiler as undefined?

1248


How can I make it pause before closing the program output window?

1006


what is the height of tree if leaf node is at level 3. please explain

2108


Given only putchar (no sprintf, itoa, etc.) write a routine putlong that prints out an unsigned long in decimal. [ I gave the obvious solution of taking % 10 and / 10, which gives us the decimal value in reverse order. This requires an array since we need to print it out in the correct order. The interviewer wasn't too pleased and asked me to give a solution which didn't need the array ].

1066


What is dynamic dispatch in c++?

1022


What is a void pointer in c?

1061


What is the meaning of && in c?

976


to find the closest pair

2300


What does != Mean in c?

1002


What does emoji p mean?

1060


Compare array data type to pointer data type

981