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

Why preincrement operator is faster than postincrement?

Answer Posted / puneet nagpal

postincrement did not increment unless it find ; so it increments after the end of statement. while the preincrement operator increment before the end of statement. so preincrement operator is faster than postincrement operator.
ex- a=10;
a++;value incremented after the end of statement but
at this point value is 10.
a++;now the value is incremented to 11.
++a; preincrement incremented within the statement now
the value is 12.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why cstdlib is used in c++?

1098


If a base class is an adt, and it has three pure virtual functions, how many of these functions must be overridden in its derived classes?

1149


What is c++ map?

1249


what does the following statement mean? int (*a)[4]

1138


Why Pointers are not used in C++?

1126


What is one dimensional array in c++?

1177


How to defines the function in c++?

1216


What is type of 'this' pointer?

1117


Does dev c++ support c++ 11?

1089


Explain class invariant.

1118


Do you know what are static and dynamic type checking?

1106


When does a name clash occur in c++?

1215


What is the use of dot in c++?

1129


what is the use of void main() in C++ language?

1172


What is the best free c++ compiler for windows?

1155