Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Is there a difference between i++ and ++i?

807599Dec 19 2006 — edited Dec 19 2006
Hi, i know that i++ is equivalent to i+1. What about ++i? Does it mean the same thing? Can I use both interchangeably in my Java program?

Hope somebody can help clarify my doubts, thanks!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 16 2007
Added on Dec 19 2006
4 comments
191 views