For this first test you will see that there isn’t a difference, it is working differently, but you cannot tell the difference in this example:

This next example highlights the differences between i++ and ++i.

Conclusion, be careful when writing code, don’t assume that things work the same way when written differently.

Leave a Reply

Your email address will not be published. Required fields are marked *