+ 2
What exactly does this line of code mean? int b= 1<--a
The full code: int a=5; int b=1<--a; How much is b after?
3 Réponses
+ 4
--a reduces a by 1 and returns the result.
So it's the same as:
b = 1<4;
1<4 is true, so b becomes 1.
If it was false, b would become 0.
+ 2
I mean the -- in the statement could be just a decrement operation and < could be comparison operator.
+ 1
Isn't 1<--a almost same than 1 < (a - 1) ?