0
957views
Determine the hierarchy of operations and evaluate the following expression:- on = ink*act/2+3/2*act+2+tig; ( ink = 4, act = 1, tig = 3.2, assume on to be an int)
1 Answer
written 18 months ago by | • modified 18 months ago |
on = ink * act/2+3/2 * act+2+tig ;
(ink=4, act=1, tig=3.2)
So, the expression will be:
on = 4 * 1/2+3/2 * 1+2+3.2
on = 4/2+3/2 * 1+2+3.2
Operation : *
on = 2+3/2*1+2+3.2
Operation : /
on = 2+1*1+2+3.2
Operation : /
on = 2+1+2+3.2
Operation : *
on …