Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Math(s) problem - puzzle

Math(s) problem - puzzle

Scheduled Pinned Locked Moved The Lounge
helpquestion
59 Posts 33 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Rick York

    If you solve it left-to-right, ignoring precedence order, then the answer is 5. An old TI calculator would give you that answer. Today's windows calculator will not: it says 120 because the multiplication is done first.

    "They have a consciousness, they have a life, they have a soul! Damn you! Let the rabbits wear glasses! Save our brothers! Can I get an amen?"

    P Offline
    P Offline
    Peter Kelley 2021
    wrote on last edited by
    #42

    "5!" = 120
    It's a clever nerdy riddle. I like it!
    I wonder if I'd have been hassled after math class for giving such an answer? and I just noticed that Microsoft Excel doesn't recognize factorials.

    1 Reply Last reply
    0
    • OriginalGriffO OriginalGriff

      And today you learn that nobody likes a smartarse ... :laugh:

      "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

      D Offline
      D Offline
      dbrenth
      wrote on last edited by
      #43

      Quote:

      smartarse

      I'm owning that.

      Brent

      1 Reply Last reply
      0
      • B Bob Beechey

        The teacher was not embarrassed but shocked that any student could be so wrong. The division MUST be carried out before the subtraction. 230 – 220 × 0.5 = 230 – 110 = 120. Try it in any scientific calculator or programming language. You are alone (I hope) in thinking the answer is 5. Are you perhaps joking?

        D Offline
        D Offline
        dbrenth
        wrote on last edited by
        #44

        As with a few readers, you missed the ! after the 5.

        Brent

        1 Reply Last reply
        0
        • D Daniel Pfeffer

          You are wrong, the teacher is right. The order of precedence in mathematical operations is (mnemonic PEMDAS): Parentheses Exponentiation Multiplication & Division Addition & Subtraction If two operations have the same precedence, they are evaluated from left to right. Your problem may be rewritten as 230 - (220 x 0.5), the answer to which is obviously not 5.

          Freedom is the freedom to say that two plus two make four. If that is granted, all else follows. -- 6079 Smith W.

          D Offline
          D Offline
          dbrenth
          wrote on last edited by
          #45

          Daniel Pfeffer wrote:

          PEMDAS

          I was taught "Please excuse my dear aunt sally". Or "Pizza everyone!, my diet already started."

          Brent

          1 Reply Last reply
          0
          • D dbrenth

            My teacher asked me to write a program on the board and solve it. I wrote:

            230 - 220 x 0.5

            and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

            Brent

            K Offline
            K Offline
            Keefer S
            wrote on last edited by
            #46

            That pesky little exclamation mark...

            1 Reply Last reply
            0
            • D Daniel Pfeffer

              You are wrong, the teacher is right. The order of precedence in mathematical operations is (mnemonic PEMDAS): Parentheses Exponentiation Multiplication & Division Addition & Subtraction If two operations have the same precedence, they are evaluated from left to right. Your problem may be rewritten as 230 - (220 x 0.5), the answer to which is obviously not 5.

              Freedom is the freedom to say that two plus two make four. If that is granted, all else follows. -- 6079 Smith W.

              K Offline
              K Offline
              Keefer S
              wrote on last edited by
              #47

              He is not wrong. You just didn't see the entire answer in your brain. The exclamation point is there for a reason.

              1 Reply Last reply
              0
              • D dbrenth

                My teacher asked me to write a program on the board and solve it. I wrote:

                230 - 220 x 0.5

                and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                Brent

                D Offline
                D Offline
                Dimitrios Kalemis
                wrote on last edited by
                #48

                Oh, come on! I immediately saw that: 5!=120

                1 Reply Last reply
                0
                • D Dougy83

                  I hadn't heard of PEDMAS before; I'm guessing it's some kind of Hollywood holiday.

                  R Offline
                  R Offline
                  Rusty Bullet
                  wrote on last edited by
                  #49

                  More likely New Orleans!

                  1 Reply Last reply
                  0
                  • R rob tillaart

                    A statisticus / mathematician will provide answers as factorial as often numbers are too big to write down. E.g. 5! is quite easy but 7000000000! is huge. Assuming the world population is 7000000000, 7000000000! is approximately the number of ways you can put their names in a list. As there are people with the same name the number is actually less but still huge. There are even statistic problems where numbers like n!! (n factorial factorial *) are used which can be even "bigger than huge". *) besides "n factorial factorial", there exist "n double factorial" which is n x (n-2) x (n-4) ... x 1)

                    D Offline
                    D Offline
                    dandy72
                    wrote on last edited by
                    #50

                    Interesting. Never knew that anyone ever used factorials other than as, shall I say, a "mathematically interesting" thing and then moving on. When it comes to extremely large (or small) numbers, I always understood that the standard was to use powers of 10, for example, googling for the weight of the earth, the result is expressed as 5.972x10^24 kg.

                    R 1 Reply Last reply
                    0
                    • D dbrenth

                      My teacher asked me to write a program on the board and solve it. I wrote:

                      230 - 220 x 0.5

                      and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                      Brent

                      E Offline
                      E Offline
                      Ed Member 1767792
                      wrote on last edited by
                      #51

                      Is it because you are saying 5! (factorial). 230 - 220 x 0.5 = 230 - 110 = 120 which is == 5x4x3x2x1 or 5!.

                      1 Reply Last reply
                      0
                      • D Daniel Pfeffer

                        "5 factorial" is not a solution; it is simply representing the answer (120) as a different equation. If you were set a problem in a mathematics test 300 - 0.5 x 150 and answered that it is 450 / 2, the teacher would be justified in marking it incomplete because it has not been reduced to the simplest terms.

                        Freedom is the freedom to say that two plus two make four. If that is granted, all else follows. -- 6079 Smith W.

                        E Offline
                        E Offline
                        englebart
                        wrote on last edited by
                        #52

                        My college math professor always told us to leave the simplification to the accountants, at least when it came to tests. No time for that. He was a great person. He later became the grad student ombudsman after putting up with us (rowdy undergrads) for three straight semesters! RIP

                        1 Reply Last reply
                        0
                        • D dbrenth

                          My teacher asked me to write a program on the board and solve it. I wrote:

                          230 - 220 x 0.5

                          and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                          Brent

                          P Offline
                          P Offline
                          Patrick Hendry 2021
                          wrote on last edited by
                          #53

                          Your answer is wrong, but not because of maths but because of your English usage. Your intention is to say the answer is 5 factorial in which case your first sentence would end with: "and announced that the answer was 5!." However, by leaving off the period, the exclamation mark ends the sentence, which means you are actually saying the answer is 5. I realize leaving off the period was deliberate to make the trick work, but it's inaccurate, and we are all engineers here :)

                          1 Reply Last reply
                          0
                          • D dandy72

                            Interesting. Never knew that anyone ever used factorials other than as, shall I say, a "mathematically interesting" thing and then moving on. When it comes to extremely large (or small) numbers, I always understood that the standard was to use powers of 10, for example, googling for the weight of the earth, the result is expressed as 5.972x10^24 kg.

                            R Offline
                            R Offline
                            rob tillaart
                            wrote on last edited by
                            #54

                            Yup, the scientific notation is far more often used (even wrote an Arduino "lib" for it). It has become handy in e.g. physics and the national debt :) Factorials, permutations and combinations are used a lot in (discrete) simulations e.g. for calculating chances of something happening. But it is true that people will often translate a chance of 1 in 100! as "will never happen" :)

                            D 1 Reply Last reply
                            0
                            • D dbrenth

                              My teacher asked me to write a program on the board and solve it. I wrote:

                              230 - 220 x 0.5

                              and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                              Brent

                              A Offline
                              A Offline
                              Andrey Logunov
                              wrote on last edited by
                              #55

                              Much Ado About Nothing

                              1 Reply Last reply
                              0
                              • D dbrenth

                                My teacher asked me to write a program on the board and solve it. I wrote:

                                230 - 220 x 0.5

                                and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                                Brent

                                J Offline
                                J Offline
                                Julian Ragan
                                wrote on last edited by
                                #56

                                Nice trap.

                                1 Reply Last reply
                                0
                                • R rob tillaart

                                  Yup, the scientific notation is far more often used (even wrote an Arduino "lib" for it). It has become handy in e.g. physics and the national debt :) Factorials, permutations and combinations are used a lot in (discrete) simulations e.g. for calculating chances of something happening. But it is true that people will often translate a chance of 1 in 100! as "will never happen" :)

                                  D Offline
                                  D Offline
                                  dandy72
                                  wrote on last edited by
                                  #57

                                  rob tillaart wrote:

                                  and the national debt :)

                                  That hurt. :-)

                                  1 Reply Last reply
                                  0
                                  • D dbrenth

                                    My teacher asked me to write a program on the board and solve it. I wrote:

                                    230 - 220 x 0.5

                                    and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                                    Brent

                                    A Offline
                                    A Offline
                                    AnotherKen
                                    wrote on last edited by
                                    #58

                                    ooh, come to think of it your teacher might be referring to order of precedence for calculating algebra expressions. You might get the "correct" answer from him if you enforce your concept by expressing it something like (230 - 220) x 0.5, for this the answer is 5. Your teacher may have been implying that multiplication is calculated before subtraction, so he might be reading it as 230 - (220 x 0.5). It might be worth it to ask him if this is what he was thinking.

                                    1 Reply Last reply
                                    0
                                    • D dbrenth

                                      My teacher asked me to write a program on the board and solve it. I wrote:

                                      230 - 220 x 0.5

                                      and announced that the answer was 5! My teacher claimed I was incorrect, but I was not. Can you please explain it to him? Thanks Hint: My teacher was quite embarrassed when I actually said the answer out loud.

                                      Brent

                                      A Offline
                                      A Offline
                                      AnotherKen
                                      wrote on last edited by
                                      #59

                                      Actually, your teacher realized you are more intelligent than him and he was embarrassed about that so he tried to cover for it by saying you were wrong. I wouldn't try to stick it to him or prove your correctness I would just let it go. There is really no point in upsetting the guy who gives you your final grade.

                                      1 Reply Last reply
                                      0
                                      Reply
                                      • Reply as topic
                                      Log in to reply
                                      • Oldest to Newest
                                      • Newest to Oldest
                                      • Most Votes


                                      • Login

                                      • Don't have an account? Register

                                      • Login or register to search.
                                      • First post
                                        Last post
                                      0
                                      • Categories
                                      • Recent
                                      • Tags
                                      • Popular
                                      • World
                                      • Users
                                      • Groups