The "z++" statement is a post-increment operator that increases the value of the variable z by 1.
Think of it like getting tickets for a concert. If you had 5 tickets and someone gives you an extra ticket after the concert, your total number of tickets would be 6.
Post-decrement: Decreases the value of a variable by 1 after using it in an expression.
Pre-increment: Increases the value of a variable by 1 before using it in an expression.
Pre-decrement: Decreases the value of a variable by 1 before using it in an expression.
Study guides for the entire semester
200k practice questions
Glossary of 50k key terms - memorize important vocab
© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.