Warning: include(/home1/hellowor/public_html/zebra0.com/Hello/include/setupLesson.php): failed to open stream: No such file or directory in /home1/hellowor/public_html/zebra0.com/visual-basic/lessons/calculations/info.php on line 6

Warning: include(): Failed opening '/home1/hellowor/public_html/zebra0.com/Hello/include/setupLesson.php' for inclusion (include_path='.:/opt/php54/lib/php') in /home1/hellowor/public_html/zebra0.com/visual-basic/lessons/calculations/info.php on line 6

Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /home1/hellowor/public_html/zebra0.com/visual-basic/lessons/calculations/info.php:6) in /home1/hellowor/public_html/zebra0.com/visual-basic/include/pagetop.php on line 2

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home1/hellowor/public_html/zebra0.com/visual-basic/lessons/calculations/info.php:6) in /home1/hellowor/public_html/zebra0.com/visual-basic/include/pagetop.php on line 2
Visual Basic

Zebra0

Learn to Program Step-by-Step

Visual Basic

Examples with Order of Operation

Equation Explanation
3 * (5 - 3 * 8 + 4)parenthesis first, within parenthesis, *  before + or -
3 * (5 - 24 + 4)if same level (+ and -), work from left to right
3 * (-19 + 4) parenthesis first
3 * (-15 )  
-45  
   
3 + (5 - 3) * (8 + 4) parenthesis first, left to right
3 + 2 * (8 + 4) parenthesis first
3 + 2 * 12 multiplication before addition
3 + 24  
27  
   
-3 * (6 * (3 - 8) + 10) inner-most parenthesis first
-3 * (6 * (-5) + 10) multiplication before addition
-3 * (-30 + 10) parenthesis first
-3 * (-20)  
60  
   
18 Mod 4 + 2 ^ 3 Exponentiation first
18 Mod 4 + 8 Mod before addition
2 + 8  
10  
   
5* 10 \ 3 -4 Multiplication before division
50 \ 3 -4 Division before minus
16 - 4  
12  

Follow through each example and make sure you understand how to get the answer.


INDEX, Arithmetic Operations, Modulus Operator, Order of Operations, Functions, Algebra,