Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Can this be solved using SQL?

Author  Topic 

vbud
Starting Member

4 Posts

Posted - 2002-07-19 : 04:13:56
There are 12 horses running for a race. Each one would carry a weight of of 0.5 kg less than the previous one, given that the 1st one would have 59kg and 12th one would carry 53kg.
The probability that each one of the horse wins depends on the 10 previous races won by the horse which is thus (1st down to 12th): 6/10, 6/10, 5/10, 5/10, 4/10, 4/10, 3/10, 3/10, 2/10, 2/10, 1/10, 1/10 respectively.
Each horse would have a jockey that has a winning mount rate as such: 4/10, 4/10, 5/10, 5/10, 6/10, 6/10, 8/10, 8/10, 7/10, 7/10, 5/10, 4/10 respectively.
Horses 1, 3, 5, 10, 11 favor good weather condition i.e shiny whereas horses 2, 4, 7 favor rainy weather conditions and horses 6, 8, 9, 12 can win in any weather condition.
Each horse would be lined up in the following positions at start: 2, 3, 5, 1, 9, 12, 7, 11, 8, 10, 4, 6 respectively.
On average, horses starting in position 2, 3, 4, 5 have 60% chance of winning whereas horses starting in position 1, 6, 7, 8 have 50% chance of winning and all other positions have 40% chance.
Each horse has a winning factor independant of their previous winning rate which is of 1/12 on average.
1.Which horse would win if the weather condition were to be good i.e shiny?
2. Which horse would win if the weather condition were to be rainy?
3. Which horse would win if the weather condition were to be good i.e shiny and the race was biased towards horse #3 by a winning factor of 3/12?
4. Which horse would win if the weather condition were to be rainy and the race was biased towards horse #5 by a winning factor of 4/12?
5. Which horse would win if the weather condition were to be shiny and the horses were to start up if the following order: 5, 12, 6, 1, 2, 8, 7, 11, 10, 3, 4, 9 respectively?
6. Which horse would win if the weather condition were to be rainy and the horses were to start up if the following order: 5, 12, 6, 1, 2, 8, 7, 11, 10, 3, 4, 9 respectively?

robvolk
Most Valuable Yak

15732 Posts

Posted - 2002-07-19 : 07:08:18
I'm sure it can (hmmmm....possible reader challenge?)

But, this is obviously a homework assignment, and you won't learn anything if we solve it for you. Therefore I'd recommend that you read up on our past Reader Challenges and their solutions:

http://www.sqlteam.com/FilterTopics.asp?TopicID=155

And also read through the SQL Team forums, you will pick up a great deal of knowledge. Read Books Online, the SQL Server documentation, it will at least show you the proper syntax for SQL statements.

You might also want to invest in Joe Celko's SQL for Smarties and/or SQL Puzzles and Answers.

Go to Top of Page
   

- Advertisement -