I thought
%
represented modulus
5 % 4 = 1
22 % 8 = 6
18 % 2 = 0
I cannot remember the books I've read any more than the meals I have eaten; even so, they have made me.
~ Ralph Waldo Emerson
Reminds me something that confused me at elementary school, when we were taught division we wouldn't use ÷ but %... like um, what? That's a percent sign. There was no confusion in the calculations provided, but c'mon! Luckily in high school we'd be using : instead (which at least resembles ÷), while for multiplication either we'd use · or ditch the sign altogether.
I remember that, but it wasn't a percent sign! Sometime between elementary and high school, teachers transitioned between the sign on the left to the sign on the right. Clearly the sign on the right is totally clear and unambiguous. Can't possibly be mistaken for anything else...
I've really only seen that in programming languages that inherited it from C (and Fortran?) and in documents aimed at such programmers. In math it's just generally written "mod".
“If I understand the standard right it is legal and safe to do this but the resulting value could be anything.”
I think that was the joke ;P
a / 2a = 1 / 2
a / 2 * a = 0.5a * a
The results are different. If you write down an expression with this kind of notation, the devision is applied to it's surrounding terms, in this case 6 and 2a, and thus results in the calculation a / (2 * a), and not in (a / 2) * a.6 / 2(1+2) = 6 / (2 * (1+2)) = 1
The problem is not about what calculation to do first, but it's more about how you can place additional parentheses without changing the expression.6/2(1+2)
6i/2i(1+2)i
6i/2i(i+2i)
6i/2(-1+-2)
6i/(-2+-4)
6i/-6
i/-1
-i
6/2(1+2)
6i/2i(1+2)i
6i/2i(i+2i)
6i/2(-1+-2)
6i/(-2+-4)
6i/-6
i/-1
-i
You added one too many i's on line two.
I know we had a discussion about this in class, partially because different calculators give different results to this. I'm pretty sure we used to consider 2/ab to be 2/(ab) for example.
I'm honestly not sure this is well-defined. When you do it on paper or in a text book, you'll use those horizontal lines for division which will make it much more clear. In that case, you'll usually not have brackets on either side of that line, which means that when you serialize it to single-line format, it's easy to forget/not-want-to to wrap both sides in brackets..
Take "46abc/2ac", I would mentally parse that as (46abc)/(2ac) while others would parse it as (46abc/2)ac. I also know that different calculators will vary in their interpretation. Maybe there is (or at least was) no standard, leaving this to be an implementation defined serialization issue..?
6/2(1+2)
6i/2i(1+2)i
6i/2i(i+2i)
6i/2(-1+-2)
6i/(-2+-4)
6i/-6
i/-1
-i
You added one too many i's on line two.
Ah. Sorry, sorry.
Here we go:
n = 6/2(1+2)
n/2 = (6/2(1+2))/2
n/2 = 3/1(0.5+1)
n/2 = 3/1(1.5)
n/2 = 3/1.5
n = 2
n = 2*2
n = 4
This is the same thing as the 48 / 2(9+3) problem that was floating around a couple years back. Math needs to be exact with its rules for everybody to get the same answer. But that question is intentionally ambiguous so I think people fallback to whatever they were taught: traditional order of operations or the PEMDAS rule. This is a good case for specifically laying out what you are asking so there isn't this kind of problem. If there was an explicit multiplication symbol between the two and parenthesis then everybody would always get the same answer.