473,398 Members | 2,088 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

finding the first 3 places in a car racing system...

50
hi , everyone. I have a logical thinking question here to be solved, any help would be appreciated.

There are 25 racing cars in a car racing. The race tracks can only allow maximum 5 cars per session, i need to find out the fastest 3 racing cars (first place, second place and third place). How many session should i conduct for the cars to get the accurate result? and how should the calculation be done?
hint is that i only been told the answer is less than 10 times. I have been calculate it should be more than 10 times..still can't figure it out...
Hope u guys can help me...
Apr 15 '08 #1
7 1338
Stang02GT
1,208 Expert 1GB
hi , everyone. I have a logical thinking question here to be solved, any help would be appreciated.

There are 25 racing cars in a car racing. The race tracks can only allow maximum 5 cars per session, i need to find out the fastest 3 racing cars (first place, second place and third place). How many session should i conduct for the cars to get the accurate result? and how should the calculation be done?
hint is that i only been told the answer is less than 10 times. I have been calculate it should be more than 10 times..still can't figure it out...
Hope u guys can help me...

25 cars 5 at a time = 5 sessions

take the top 3 cars from each session to race again = 15 cars

15 cars 5 at a time = 3 sessions

top three from each session = 9 cars

9 cars 3 at a time = 3 sessions

take the 1st place finisher from each session you have your top three racers

11 sessions total
Apr 15 '08 #2
beemomo
50
Dear Stang02GT,

I have proposed the same solution as u what u did just now, but this not the ideal anwser as the interviewer want the answer which is not more than 10.

Any idea on this? thanks ya
Apr 15 '08 #3
Stang02GT
1,208 Expert 1GB
I got it.


25 cars 5 at a time = 5 sessions

take the 1st place car from each session = 5 cars

make them race and take the top 3 from that race

for a total of 6 sessions
Apr 15 '08 #4
Stang02GT
1,208 Expert 1GB
I found another way to do this, but i haven't heard anything back as to weather my second answer works for you or not?
Apr 16 '08 #5
RedSon
5,000 Expert 4TB
I got it.


25 cars 5 at a time = 5 sessions

take the 1st place car from each session = 5 cars

make them race and take the top 3 from that race

for a total of 6 sessions
Why not just do 25 cars 5 at a time and then take the top three based on time? No need for the final session.
Apr 16 '08 #6
Stang02GT
1,208 Expert 1GB
Why not just do 25 cars 5 at a time and then take the top three based on time? No need for the final session.
I think there are about 20 different ways you can do this...thats another....i have about 4
Apr 16 '08 #7
beemomo
50
Dear Stang02GT and Red Son,

I need to apologize first as I am replying you guys very late because there is problem with my Internet connection.
Thank you very much for all your helps.

I manage to obtained one of the solution suggested by my friend.

************************************************** ******************************************
Firstly name each car with a number
--------------------
| 1 | 2 | 3 | 4 | 5|
| 6 | 7 | 8 | 9 | 10|
| 11| 12| 13| 14| 15|
| 16| 17| 18| 19| 20|
| 21| 22| 23| 24| 25|
---------------------
times used :5

Then race each group and we got this result :

--------------------
champion| 1 | 2 | 3 | 4 | 5|
second | 6 | 7 | 8 | 9 | 10|
third | 11| 12| 13| 14| 15|
--------------------

After that we race all car that get second place : 6,7,8,9,10
Then we get the top 3 answer, let said is 6,7,8 win...mean 9 and 10 lost.
Then we eliminate those low chances to win.

times used:6

now the diagram will become like that :
--------------------
champion| 1 | 2 | 3 | 4 | 5|
second | 6 | 7 | 8 |
third | 11| 12| 13|
-------------
Then we need to eliminate those low chance again...
No.6 may has chance to get second place in overall race. Now look at row 1, no.2 win no.7,no.7 get second place on last race, in other words no.7 can’t beat no.2 even it get second place on last race. So no.7 has the possibility to get 4th place in overall race. At this moment, we know that our diagram will become like this :
--------------------
champion| 1 | 2 | 3 | 4 | 5|
second | 6 |
third | 11|
-----

Then we race with 5 champion car.
Then the diagram will become:
-------------
champion| 1 | 2 | 3 |
second | 6 |
third | 11|
-----
times used:7

Then lastly, race again with no1, 2, 3, 6, 11 then will get the answer.

times used: 8

************************************************** ******************************************

As I know this is a logical test. I think there is no fixed answer or correct answer for the question, the tester might use the answer given by me to test my logical thinking concept.

Many thanks again for all your replies and answers. Cheers!
Apr 25 '08 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Noam Dekers | last post by:
Hi all, I would like to find a word stored in a text file. Structure: I have one file named keyWords.txt that stores some key words I'm interested in finding. In addition I also have a file...
17
by: Sean Ross | last post by:
Hi. Recently I made a small script to do some file transferring (among other things). I wanted to monitor the progress of the file transfer, so I needed to know the size of the files I was...
12
by: jeff elkins | last post by:
I'm creating an app that relies on a configuration file at launch. The file will always exist in the app's installation directory, but I have no control over where that might be. Is there an...
3
by: Brent Bortnick | last post by:
Does anyone know how to find out the number of decimal places a number has. I need this info so that i can round to 3 decimal places if the number has 3 decimal places or to 2 decimal places if...
0
by: Tipwinners | last post by:
This is a multi-part message in MIME format ---=_AZROORDVTILVT.01AA02E60255CJO.02940930 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit This is an HTML...
2
by: TadPole | last post by:
Hi all, My main problems are::::::::: 1. Set a value within a block container that can be used and changed by subsequent templates/block-containers/tables etc.. 2. get/determine/find the...
4
by: Larry | last post by:
I have a Perl script using DBD::DB2, that runs during system startup on a Solaris system. The script is working fine during startup on many machines, except on one machine it fails complaining...
2
by: Fred Wilson | last post by:
Hello, How does one go about finding all the tables that have a particular field name? For example a field name "EVENT_CODE" I would like to find all the places in the database this is...
42
by: aarklon | last post by:
Hi all, see:- http://mathforum.org/library/drmath/view/54456.html
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.