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. The Three Switches

The Three Switches

Scheduled Pinned Locked Moved The Lounge
htmllampcomquestion
47 Posts 37 Posters 1 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.
  • P Peter_in_2780

    The classic solution (which I won't give away) may not work too well with modern LED globes! CFLs maybe. Cheers, Peter

    Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012

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

    An in depth exploration of the efficiency of lighting. I think I found this through an image search a while back. http://physics.ucsd.edu/do-the-math/2012/05/spectral-extravaganza-the-ultimate-light/[^]

    1 Reply Last reply
    0
    • J Jorgen Andersson

      Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

      Wrong is evil and must be defeated. - Jeff Ello

      S Offline
      S Offline
      SeattleC
      wrote on last edited by
      #38

      Had this question at a job interview. It's a lateral thinking exercise. My experience with software development over 35 years is that lateral thinking is virtually never a part of the mental toolkit for software development. Oh, by the way, the solution requires that the bulb be an incandescent bulb. It won't work with an LED bulb or electroluminescent night light.

      1 Reply Last reply
      0
      • J Jorgen Andersson

        Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

        Wrong is evil and must be defeated. - Jeff Ello

        K Offline
        K Offline
        KLSmith
        wrote on last edited by
        #39

        What if you have an LED bulb in in the attic?

        1 Reply Last reply
        0
        • J Jorgen Andersson

          Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

          Wrong is evil and must be defeated. - Jeff Ello

          T Offline
          T Offline
          Tiger12506
          wrote on last edited by
          #40

          Here's my problem with the accepted solution -- How do you know that these aren't 3-way switches?? "One of them controls the lamp in the attic" -- which says nothing about whether the other two switches also control the lamp in the attic.

          1 Reply Last reply
          0
          • J Jorgen Andersson

            Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

            Wrong is evil and must be defeated. - Jeff Ello

            J Offline
            J Offline
            jkirkerx
            wrote on last edited by
            #41

            Usually up is on such as decora, or the old switches were marked on and off. Or take off the panel, and use a current meter to determine the on position, or volt meter or test light. Turn all 3 switches on.

            1 Reply Last reply
            0
            • J Jorgen Andersson

              Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

              Wrong is evil and must be defeated. - Jeff Ello

              K Offline
              K Offline
              Keviniano Gayo
              wrote on last edited by
              #42

              Its so simple.. you turn ON ALL switches

              1 Reply Last reply
              0
              • J Jorgen Andersson

                Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

                Wrong is evil and must be defeated. - Jeff Ello

                F Offline
                F Offline
                Fred Pedro
                wrote on last edited by
                #43

                I'd say I'll use logic gates for this one. Not sure if it will be valid, don't care either if it is or not. :laugh: :laugh: Say we are talking about OR gates, we can have a single switch be turned differently from the other two switches. We will then have 1+0+0=1 or 1+1+0=1. Then the lamp is on.

                1 Reply Last reply
                0
                • J Jorgen Andersson

                  Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

                  Wrong is evil and must be defeated. - Jeff Ello

                  M Offline
                  M Offline
                  Member 10447195
                  wrote on last edited by
                  #44

                  Assuming the bulb is incandescent and the switches are 1 -2 - 3 turn on switches 1 and 3 - wait 10 minutes - turn off switch three go to the attic - if the light is on, switch one activates the lamp if the light is off, feel the bulb if it is warm, switch 3 activates the lamp if it is cold, switch 2 activates the lamp. SushiSlayer

                  1 Reply Last reply
                  0
                  • J Jorgen Andersson

                    Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

                    Wrong is evil and must be defeated. - Jeff Ello

                    B Offline
                    B Offline
                    Bassam Abdul Baki
                    wrote on last edited by
                    #45

                    I got that in less than a minute a few years back. :-D

                    Web - BM - RSS - Math - LinkedIn

                    1 Reply Last reply
                    0
                    • J Jorgen Andersson

                      Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

                      Wrong is evil and must be defeated. - Jeff Ello

                      U Offline
                      U Offline
                      User 10714135
                      wrote on last edited by
                      #46

                      I haven't looked at the other posts yet, so I'm throwing my solution in before I go reading. Turn on the first switch. Wait a while. Turn off the first switch. Turn on the second switch. Go upstairs. If the light is on, it's the second switch. If the light off, feel the bulb. If it's hot, it's the first switch, otherwise it's the third switch.

                      1 Reply Last reply
                      0
                      • J Jorgen Andersson

                        Downstairs in a house are three identical on-off switches. One of them controls the lamp in the attic. The puzzle is to work out which switch controls the lamp. The rules are as follows. You are allowed to manipulate the switches all you like, and then you are allowed a single trip to the attic. How do you do it? To clarify: When you are downstairs there is no way to see into the attic, or see reflected light from the attic. Once you have gone to the attic you are not allowed back to the switches. <edit>you can also assume original state of all switches to be off.</edit><hint>Otherwise it won't work</hint> Note: If you already know the answer, or reads the newspaper where I nicked the puzzle from, then please don’t write it up immediately in the comments! Give those who have never heard it before a chance to suffer, I mean enjoy finding the solution.

                        Wrong is evil and must be defeated. - Jeff Ello

                        K Offline
                        K Offline
                        KellyKimble
                        wrote on last edited by
                        #47

                        I attempted to prove the solution is viable but in the attempt I broke my ankle stumbling over all the junk in the pitch black attic as I tried to get to the light. :(( >>> Mental note: Only attempt this during the daytime and only for attics with windows <<< :laugh:

                        - Kelly

                        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