is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.
CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.
Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.
Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.
Step 1: Number the barrels from 1 to 240.
- Rachit Srivastava March 09, 2014Step 2: Mix small quantity (which can kill a person) of wine from first 15 barrels, then next 15 and so on.
1-15, 16-30, 31-45, 46-60, .............196-210, 211-225, 226-240.
Doing so we will have 16 different sets of mixtures.
Step 3: Number the first (mixture of first 15 barrels) mixture as1, second as 2, and so on the last one as 16.
Step 4: Feed the slaves according to the binary number system, like the first mixture is feed to the first ,2nd to the 2nd , 3rd mixture to both the slaves 1st & 2nd and so on the last (16th mixture) to fifth slave only.
Step 5: Now after 24 hours we will come to know which mixture is poisoned and are left with only 4 slave alive to be tested on.
Step 6: Now number those 16 barrels from 0 to 15 and feed them from each barrel according to the binary number like 0 is fed to none, 1 one is fed to the first slave, 2nd to the second slave, and so on the 15 to all the four slaves.
Step 7: After next 24 hours we will come to know exactly which barrel is poisoned.
Do tell me if you find any error in the solution as this is my first ever comment to any problem, any suggestion is highly appreciated.