4 ms·
How is that ambiguous? PEMDAS and since multiplication and division have the same rank, you go left to right. Pretty clear if the calculators follow the basic o
by jetti 15y ago
How is that ambiguous? PEMDAS and since multiplication and division have the same rank, you go left to right. Pretty clear if the calculators follow the basic order of operations.
- baddox 15y agoAll infix notations (without sufficient parentheses) require an agreement (implicit or explicit) among all concerned parties. This is nothing new. The same ambiguity occurs with the unary negation operator, as in -5^2. While I wouldn't choose it, I don't think it's entirely unreasonable to give the "multiplication by juxtaposition" operator greater precedence than the normal multiplication and division operators.
- uiri 15y agoIf you write the expression as a fraction without anything beside it being multiplied, it is ambiguous as to whether (1+2) ought to go above or below the fraction bar. The fact that parentheses/brackets ought to be resolved before anything else complicates things because 6/2 * 3 could reasonably be interpreted either way. An unambiguous way to write it would be either as (6/2) * 3 or as 6/(2*3).
- excuse-me 15y agoBEDMAS is easier to remember There is an ambiguity if Division comes before Multiplication - although in this case you assume left->right
- patricklynch 15y agoHow is that ambiguous? Although that was probably rhetorical: It's ambiguous because most people[1] automatically view implicit multiplication as higher rank than both division and explicit multiplication. -- [1]this is a wild guess with no data to back it up edit: baddox's answer is much better