What is arithmetic priority of an algebric experssion. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What is arithmetic priority of an algebric experssion.

give the correct order of add,sub,mul,div,mod

27th Jan 2017, 7:27 AM
Hariprasath R
1 Answer
+ 2
Multiplication, Division, Modulo in left-to-right order, then Addition, Subtraction in left-to-right order, so whichever comes first from the left is evaluated first, but anything in parenthesis () takes priority over what's outside.
27th Jan 2017, 7:30 AM
Blightedsage
Blightedsage - avatar