Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: SQL Fun Challenge #3

Re: SQL Fun Challenge #3

From: Andy Hassall <andy-google-groups_at_andyh.co.uk>
Date: 12 Mar 2004 04:56:15 -0800
Message-ID: <13e4adad.0403120456.1ee2c187@posting.google.com>


Daniel Morgan <damorgan_at_x.washington.edu> wrote in message news:<1079077451.572264_at_yasure>...
> "Train 1" leaves station A heading east at 10:00am, "Train 2" leaves
> station B heading west at the same time. The two trains are moving
> towards each other on the same track and are 114 miles apart.
>
> The trains move at a constant 50 miles per hour. There is a bird perched
> on "Train 1". The bird begins to fly east as soon as "Train 1" begins
> to move. The bird flys at a constant 20 miles per hour and flies back
> and forth between "Train 1" and "Train 2" as the trains approach each
> other. The bird has perfect recoil (it spends 0 time perched on either
> train and experiences no acceleration and no deceleration). How many
> miles does the bird fly before the trains collide?

Hang on - if the trains are doing 50mph, and the bird is only doing 20mph, it's not going to reach "Train 2" before "Train 1" does?

As the trains are going at the same speed, they'll crash in the middle of the course. So just need to work out how far the bird can go at 20mph before the trains reach the midpoint at 50mph.

SQL> select 114/2/50*20 as birdmiles from dual;

 BIRDMILES


      22.8

If the bird was flying at 20mph *relative* to the train it just took off from, so doing 70mph, then it gets trickier! Received on Fri Mar 12 2004 - 06:56:15 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US