+ 5
[Solved]Unexpected output. Explain why🤔
https://code.sololearn.com/cOMmRPu13WQM/?ref=app Question start on line 30 and ends at line 32
3 Respuestas
+ 5
There's nothing unexpected here. Have a look at my code. I have two variables,
a = 16
b = 18
Notice the statement : a = ++b
Here, b's value is incremented first, since it's a prefix and then a is assigned the value of b. So the final values of a and b are the same, that is, 19.
https://code.sololearn.com/cpx40RMR2uSM/?ref=app
+ 5
So you mean that the output must be the same. I didn't see that coming.Thank you😁
+ 3
<Derrickee/> You're Welcome 😄