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
0
49views

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 …

Create a free account to keep reading this post.

and 3 others joined a min ago.

Please log in to add an answer.