48÷2(9+3) = ?

Correct, therefore I still wonder why biocow thinks 50% of the people get it right

I have found that 50% of the time, people don't have actual data to backup statements that begin with "half the time...".

biocow:
... It's math. There can only be 1 answer.

What about

f(x) = sin (x)

What's the root? That has infinite answers.

Or a quadratic. That always gives two answers (both aren't always plausible, but you still get two answers). Lots of mathy stuffs yield two+ answers.

Basic math.

You guys have the units all wrong:

9 cups shortening + 3 eggs
add 24 cups flour, stir and bake
makes biscuits for 48 people

the answer is: biscuit

Your question fails the basic test. Does it compile?

sketch_apr21b:2: error: stray '\' in program
sketch_apr21b.cpp: In function 'void setup()':
sketch_apr21b:2: error: expected `;' before 'u00f72'

Therefore there can be no answer. Excepting 42 of course. :wink:

I've just googled this and a site pointed out that implied multiplication has a higher precedence than division. For example, 2/5x would normally be interpreted as 2/(5x)

Implied multiplication may have an implied higher precedence than division, not a mathematical precedence...

...plus, you shouldn't always believe what you google.

AWOL:
...plus, you shouldn't always believe what you google.

...but...but...google is always right!

Not just google.... the InterWebs! If it's on the InterWebs it MUST be true!

What's the interwebs?

Google is the internets

CowJam:
I've just googled this and a site pointed out that implied multiplication has a higher precedence than division. For example, 2/5x would normally be interpreted as 2/(5x)

Reference?

I have seen it claimed that 3-1+5 equals -3 on the basis that you evaluate it as 3 - (1 + 5). The reason given is that BODMAS (or BIDMAS/BEDMAS) stands for Brackets, Exponents, Division, Multiplication, Addition, Subtraction. Therefore since addition is before subtraction you add 1 to 5, and then you subtract that from 3, giving -3.

However this is wrong. Multiplication/division, and addition/subtraction have equal priority and are evaluated left to right.

Wikipedia:

Many programming languages use precedence levels that conform to the order commonly used in mathematics, though some, such as APL or Smalltalk, have no operator precedence rules (in APL evaluation is strictly right to left, in Smalltalk it's strictly left to right).

KE7GKP:
Not everybody agrees with that.

Yes, I see that.

Well the question is undefined then. Without specifying the base of the numbers, the domain in which we are working (eg. maths, APL, Smalltalk, C, Swahili, Martian) it cannot be answered.

And that is the fundamental issue. Not everybody agrees with that.

Heck, we can't all even agree on which side of a road to drive on. :wink:

retrolefty:

And that is the fundamental issue. Not everybody agrees with that.

Heck, we can't all even agree on which side of a road to drive on. :wink:

Now you're trying to confuse things with geometry.

Vehicle A belongs to me
Road B is whatever road vehicle A is on currently
Road B is bisected by line C
All roads belong to me
Therefore vehicle A may drive on either side of line C

Heck, we can't all even agree on which side of a road to drive on.

Depends which way you're travelling :smiley:

mowcius:

Heck, we can't all even agree on which side of a road to drive on.

Depends which way you're travelling :smiley:

Well that would be my way or the highway. :wink:

shouldn't it be following order of operations so that inside the parenthesis is first this would make it two, but as for the other approaches, I did not really get them.

I did not really get them.

It all boils down to whether you do the un-parthenthesized multiplication or division first:
48÷(2(9+3)) or (48÷2)(9+3)
and THAT depends on whether you believe that implied multiplication (2x) has a different precedence than explicit multiplication (2*x), whether there's an explicit precedence of multiplication vs division, and/or whether you believe in left-to-right evaluation or something else. All of which are NOT consistently defined.

CowJam:
I've just googled this and a site pointed out that implied multiplication has a higher precedence than division. For example, 2/5x would normally be interpreted as 2/(5x)

48÷2(9+3) = y
If we say that (9+3) is x, then x = 12.
That makes it 48÷2x, or 48*(212)
2
12 is 24.
48÷24=2, so 2 is my answer.

Arduino disagrees though:

void setup(){
  Serial.begin(9600);
  Serial.print(48/2*(9+3));
}
void loop(){}

Serial output: 288.

Onions.