posted 13 years ago
I don't understand why this code prints out 1,0
It seems to me that the answer should be 1, 1
Here is my logic process.
i++ resolves to 1
i(1) is passed to f1 which prints out 1,
then we return 0 to the original expression and add it to the 1(i++) that is already there.
Resulting in a second 1 printing.