Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
45

edit:
In XP SP2:
If you use the calculator in "Standard" mode, it will evaluate 6 + 3 * 5 as 45.

When you switch to "Scientific", it will evaluate it as 21.

(order of precedence puts "*" higher than "+", and is evaluated first, same as if the expression were written in source code ("C", and others)).

Just for fun, did the same equation in OS-X, using Apple Calculator app:
Either Basic or Scientific - 21 is the result. I'll take consistent.
If you use RPN, the operators are evaluated in the order entered, with 45 as the result.

2nd Edit:
Tried same experiment with Palm T|X:
Same inconsistencies as Windows: Basic = 45. Advanced = 21.
Nice....... 🙄
 
Guess that got a bit off topic - but was interesting (at least it was interesting at 1:30am....)
 
If you use RPN, the operators are evaluated in the order entered, with 45 as the result.

No, if you calculate 6 + 3 * 5 using RPN you get 21 if you:
- put 6 on the stack (6 ENTER) [Stack contains: 6]
- then you enter 3 and 5 and multiply them (3 ENTER 5 *). [Stack contains: 6 15],
- Finally you press + to add these numbers [Stack now contains: 21].
So, you would type "6 3 5 * +" in RPN.

If on the other hand you want to calculate (6 + 3) * 5, you type "6 3 + 5 *" to get 45.
 
45

edit:
In XP SP2:
If you use the calculator in "Standard" mode, it will evaluate 6 + 3 * 5 as 45.

When you switch to "Scientific", it will evaluate it as 21.

(order of precedence puts "*" higher than "+", and is evaluated first, same as if the expression were written in source code ("C", and others)).

Just for fun, did the same equation in OS-X, using Apple Calculator app:
Either Basic or Scientific - 21 is the result. I'll take consistent.
If you use RPN, the operators are evaluated in the order entered, with 45 as the result.

2nd Edit:
Tried same experiment with Palm T|X:
Same inconsistencies as Windows: Basic = 45. Advanced = 21.
Nice....... 🙄


well, you DO realize that regular calculators do NOT prioritize equations, right? They calculate equations as they are typed. 2+2x4 will come out to be 16. They read it as 2+2 = 4 x4 = 16. I was taught that in elementary school.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.