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

for(i=0;i=printf("Hello");i++);
printf("Hello");
how many times how will be printed?????????

Answer Posted / kalyan chukka

Here in the loop it given as i=0;i=printf("Hello");
So Printf function returns how many no of charecters it
printed so it takes 5 so loop is

for (i=0;i=5;i++) so loop will be this
in the above loop first i=0 and then we assign i=5 so loop
will become for(i=5;i++) it becomes infinite loop hello
printed infineite loop.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which is the best website to learn c programming?

1136


What is difference between %d and %i in c?

1310


How are pointers declared in c?

1115


what is use of malloc and calloc?

1954


What is a #include preprocessor?

1225


A global variable when referred to in another file is declared as this a) local variable b) external variable c) constant d) pointers

1284


How do I convert a string to all upper or lower case?

1174


What is the function of multilevel pointer in c?

1140


define string ?

1172


what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;

2698


Explain enumerated types.

1088


What are the restrictions of a modulus operator?

1168


What is strcmp in c?

1219


What is difference between scanf and gets?

1372


Does c have circular shift operators?

1302