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

main()
{
int i=5;
printf("%d%d%d%d",i++,i--,i);
}

Answer Posted / sravankumar

printf() function evaluates from right to left

printf("\n %d %d %d",i++,i--,i);
4 5 5
<- <- <- <- <-evaluation of expression
but prints as the way we mentioned in printf() function
i.e first i = 5
then i--= 5 because it is post decrement
then i++= 4 this because i is decremented in above, and
not incremented immediately because is post
increment
So output is : 4 5 5

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is #define size in c?

1273


What is c variable?

1103


How do I read the arrow keys? What about function keys?

1154


What will the code below print when it is executed?   int x = 3, y = 4;         if (x = 4)                 y = 5;         else                 y = 2;         printf ("x=%d, y=%d ",x,y);

1948


how to introdu5ce my self in serco

2055


What does s c mean on snapchat?

1190


a character or group of characters that defines a register,or a part of storage a) memory b) byte c) address d) linear list

1057


What is the use of typedef in c?

1089


Can true be a variable name in c?

1092


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

1267


How would you rename a function in C?

1094


How can I discover how many arguments a function was actually called with?

1116


What is a 'null pointer assignment' error?

1252


Can we change the value of #define in c?

1061


What is the general form of a C program?

1074