I understand how post-incrementing and pre-incrementing in Java works, and I've read countless other threads/questions from other people regarding this same topic. BUT! I have yet to learn WHY post-incrementing has higher precedence than pre-incrementing in Java.
Does anyone know?
To my knowledge, post-incrementing having higher or lower precedence than pre-incrementing will not affect your programs' results since there aren't other unary operators that could interfere with post/pre-incrementing. Furthermore, ++ isn't a binary operator, so it's not like it interferes with +, -, *, / and %. So therefore.. WHY? WHY does post-incrementing have higher precedence than pre-incrementing?
My motivation is this: Java's been made so that post-incrementing has a higher precedence than pre-incrementing and I haven't yet seen any example where the result differs depending on these rules. So I don't understand why post/pre-incrementing doesn't have the same level of precedence
I'd be very happy if anyone could enlighten me! :)
Here's one official site that states precedence rules/levels in Java: http://docs.oracle.com/javase/tutorial/java/nutsandbolts/operators.html