0

Output of C code

Can someone explain the output of this C code? I am having trouble understanding the operator precedence in this example. https://code.sololearn.com/c4N689vprQit/#c

19th Oct 2020, 6:16 PM
Edward Finkelstein
Edward Finkelstein - avatar
2 Answers
+ 4
Comma operator works from left to right and the final result is the rightmost expression .
19th Oct 2020, 6:44 PM
Hima
Hima - avatar
+ 1
Ah, I see, ok, that makes sense, thank you Hima.
19th Oct 2020, 7:48 PM
Edward Finkelstein
Edward Finkelstein - avatar