Computer Science, asked by malarma, 1 year ago

Evaluate the following expression according to operator precedence used in C.
10-3%8+6/4
10
4
8
6

Answers

Answered by writersparadise
2

According to operator precedence in C,


/ and % operators are evaluated first


+ and - operators are evaluated next


The associativity or order of operation of the above operators in an expression is from left to right.


Thus,


10-3%8+6/4 = 10-3+1


                        = 7+1            


=>10-3%8+6/4 = 8
Similar questions