Problem of the Day
A new programming or logic puzzle every Mon-Fri

100m Dash

A brother and sister run the 100m dash after school to practice for an upcoming track meet. In the first race the sister beats her brother by 5 yards. They decide to race again but to make things more fair the sister then starts 5 yards behind the original starting line and they race again. Assuming the brother and sister run at the same speed as they did during the first race, who wins the second race?

Enjoy your weekend!

Permalink: http://problemotd.com/problem/100m-dash/

Comments:

  • Akshay Bist - 8 years, 9 months ago

    If the sister finished the first race in time T seconds(and brother covered 95 meters in T seconds), then with a 5 yard(4.572 meter) head start, the brother finishes the second race in 1.04791 * T seconds. Sister takes 1.04572 * T seconds. So the sister wins, by a fraction.

    reply permalink

  • Tim at DataRobot - 8 years, 9 months ago

    I think Akshay Bist has it correct, although I conceptualized it differently:

    If you say that the duration of the first race was one U (a unit of time), then the sister runs 100 meters per U and the brother runs 95 meters per U. One U, 5 meters apart.

    If you start the sister 5 meters behind the brother, then one U later the sister will have run the lagged 5 meters, plus 95 meters (a total of 100 meters in one U), and the brother will have run his usual 95 meters in a single U.

    At this point, they're both at the 95 meter mark, running a 5 meter race to the finish. And the sister easily outpaces his brother, because she's running faster. The victory goes to her again.

    reply permalink

  • Driphter - 8 years, 9 months ago

    Clojure!

    (defn- yards->meters
      [yards]
      (/ yards 1.0936))
    
    (defn solution []
      (let [brospeed (- 100 (yards->meters 5))
            sisspeed 100
            brotime (/ 100 brospeed)
            sistime (/ (+ 100 (yards->meters 5)) sisspeed)]
        (if (< brotime sistime)
          :brother
          :sister)))
    
    ; user=> (solution)
    ; :sister
    

    reply permalink

  • hugo - 8 years, 6 months ago

    The sister will outrun the brother with 8.2296 inches. Doen't matter how fast they will run (if 100m/s or 5m/s), as long as they run at a constant speed.

    reply permalink

Content curated by @MaxBurstein