New course! Every coder should learn Generative AI!
Try a free lesson0
What is the difference between- i+1 and i++?
2 Answers
+ 2
i++ increments i by one and produces the rvalue i. i+1 produces the rvalue i+1
0
i++ is known as shorthand increment.Both are same.