Because the expression
You may want to do:
which evaluates to
num1 + 1.
Note however that both expressions increment
num1 by one.
num1 in the next statement evalutes to the incremented value.
In C, why doesn’t num1++ increment in the printf()?
num1++ does increment
num1 but it evaluates to
num1 and that evaluation is what you are passing to
solved Why does integer++ not increment integer value?