Why preincrement operator is faster than postincrement?
Answer Posted / sanish joseph
the pre inc operator increments the value of that particular
variable on that line itself
the post inc operator increments the value of that
particular variable after going on the next line
in simple words
eg.
e=5; on this line value of e=5
e++; on this line value of e=5
++e; on this line value of e=7
| Is This Answer Correct ? | 27 Yes | 9 No |
Post New Answer View All Answers
Write is a binary search tree? Write an algo and tell complexity?
What are the various arithmetic operators in c++?
When you overload member functions, in what ways must they differ?
What is the history of c++?
Write a short code using c++ to print out all odd number from 1 to 100 using a for loop
Do you know what are pure virtual functions?
How does the copy constructor differ from the assignment operator (=)?
Differentiate between an array and a list?
How can I learn c++ easily?
Is empty stack c++?
What is diamond problem in c++?
What is a constant reference?
Is there a c++ certification?
What are register variables?
Write about all the implicit member functions of a class?