The answer's five, anyway.
[1] This facsimile operated in part by synAC.So if 2(1+2) is a single term we should distribute like I said, right?
I think I hate this question now.
BTW, I'm a chick.Tzetze: Pf, fool. The answer is Graham's number.
ᐅᖃᐅᓯᖅ ᐊᑕᐅᓯᖅ ᓈᒻᒪᔪᐃᑦᑐᖅAre you sure? Remember, function application is left-associative.
[1] This facsimile operated in part by synAC.The moral of this story is that people should stop using ÷ as the division sign and instead use the fraction form for clarity. =P
edited 30th Apr '11 6:47:20 PM by nightwyrm_zero
That's kind of annoying to do in most textual thingamajiggers though... TeX is the obvious solution to bring us into the fourth millenium.
[1] This facsimile operated in part by synAC.What function does 2 represent here? Also
The answer is «Use TeX you wrigglers»
the future we had hoped forA function that pushes the number 2 to the stack, of course!
[1] This facsimile operated in part by synAC.Technically, 2 is a token that the Forth textual interpreter is unable to find in the dictionary, but can convert to a number, and thus compiles as a reference to the (LITERAL) routine followed by the number.
Therefore, 6 ÷ 2 ( 1 + 2 ) parses as "push 6, divide top two elements on stack, push 2, then ignore the comment in parentheses".
So you had better have a value on the stack to start with, lest you underflow.
EDIT: okay, for efficiency you may wish to define the common constants such as 0, 1, and 2 with direct machine-code implementations. In which case 2 would be a routine to push 2 to the stack.
It's far more evilfun to define : 2 3 ; however.
edited 30th Apr '11 7:39:59 PM by Tangent128
Do you highlight everything looking for secret messages?5/2Y = 5/(2*Y), not (5/2)*Y. (Not that it will mate any difference in this specific example.)
Except I can type 5/2Y into any calculator with algebra handling and get 2.5 * Y. It's implicit grouping among lazy typists, not correct syntax.
And in my calculator, -4^2 is -16.
I'm convinced that our modern day analogues to ancient scholars are comedians. -0dd1My calculator gives WARNING: LOW BATTERY.
[1] This facsimile operated in part by synAC.Then you should change the battery, shouldn't you?
I'm convinced that our modern day analogues to ancient scholars are comedians. -0dd1That's because -4^2 is -16. (-4)^2 is what you're looking for, because -<number> is an implicit (-1)*<number>.
You are apparently not considering the idea that the syntax your calculator uses is a representation of the syntax mathematicians use and not the other way around.
I'm convinced that our modern day analogues to ancient scholars are comedians. -0dd1No, that's exactly what I'm arguing. Calculators interpret it that way because that's the accepted style.
Like, if I wrote 20-4^2 you'd know I was looking for 4. So why would -4^2 not be -16?
edited 30th Apr '11 8:24:10 PM by Pykrete
Guess what I want now: An old HP calculator.
[1] This facsimile operated in part by synAC.Because binary operators carry lower precedence than unary operators.
edited 30th Apr '11 8:27:48 PM by BlackHumor
I'm convinced that our modern day analogues to ancient scholars are comedians. -0dd1You realize that was written in the section entitled "Gaps in the standard" to contrast with written convention, and cited such marvelous mathematical constructs as Excel, right?
If you're going for (respectable) programming languages it doesn't even come up, since you usually have to use an explicit pow(a,b) for exponents or anything else that would normally come between parentheticals and multiplication in written convention.
edited 30th Apr '11 8:35:38 PM by Pykrete
It wasn't cited, and it was pretty irrelevant anyways, so I dropped the link.
Point is still valid; the reason they use that convention in Excel is that it's the convention that everyone uses. But I don't really want to dwell on a link I'm not even linking to anymore.
I'm convinced that our modern day analogues to ancient scholars are comedians. -0dd1Hell, for squaring there's a good chance you'll probably just use x*x(which, historical note, is actually what mathematicians used to use)
edited 30th Apr '11 8:39:52 PM by Ponicalica
the future we had hoped forThis is why we should do mathematics the Indian way. Scan that shit, bro
[1] This facsimile operated in part by synAC.
But, yeah. I'm with you on this. 2(1+2) is a single term.
edited 30th Apr '11 6:21:04 PM by GreatLich