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 difference between i++ and ++i?

Answer Posted / geetha

i++ and ++i mean the same thing when they form statements
independently,they behave differently.
for example:
i=5;
d=++i;
in this case the value is i,d =6.bcoz first increment and
next assign the value
i=5;
d=i++;
in this case the value of d=5 and i=6.bcoz first assign the
value next increment and it will be change the value i=6.

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how many levels deep can include files be nested?

1060


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

2624


What is formal argument?

1122


What is an array in c?

1036


What is calloc malloc realloc in c?

1046


Why is extern used in c?

1082


a parameter passed between a calling program and a called program a) variable b) constant c) argument d) all of the above

1099


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

978


When do you not use the keyword 'return' when defining a function a) Always b) Never c) When the function returns void d) dfd

1043


What is getch?

1170


Is there a way to switch on strings?

1069


Please send me WIPRO technical question to my mail ID.. its nisha_g28@yahoo.com please its urgent

2111


hai iam working in sap sd module for one year and working in lumax ind ltd in desp department but my problem is i have done m.b.a in hr/marketing and working sap sd there is any combination it. can you give right solution of my problem. and what can i do?

2111


Calculate the weighted average of a list of n numbers using the formula xavg = f1x1+f2x2+ ….+ fnxn where the f’s are fractional weighting factors, i.e., 0<=fi<1, and f1+f2+….+fn = 1

4251


write a program to create a sparse matrix using dynamic memory allocation.

4880