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

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

Answer Posted / ravinder

Ans 12,
as addition will takes place from left to right
step1: i++ = 5;
step2: value of i will be updated before taking value of
another operand and hence i = 6;
step3: ++i = 7 as first increment will happen and then value
will be used.
final result: 5 + 7 = 12;

Is This Answer Correct ?    24 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does it mean when a pointer is used in an if statement?

1117


explain what is fifo?

1090


What do you mean by scope of a variable in c?

1017


What is the difference between null pointer and wild pointer?

1205


What is scanf_s in c?

1129


Write a program to print factorial of given number using recursion?

1023


What does %2f mean in c?

1232


What does calloc stand for?

1174


swap 2 numbers without using third variable?

1141


Where does the name "C" come from, anyway?

1177


Apart from dennis ritchie who the other person who contributed in design of c language.

1408


What is struct node in c?

1082


What are loops in c?

1016


What is the difference between ++a and a++?

1226


Explain what does it mean when a pointer is used in an if statement?

1076