Microsoft

  www.microsoft.com
  www.microsoft.com

Interview Question

Intern Interview

How would you determine the heaviest marble among 9 marbles

  where one is heavier and you can use the scale only twice?
Answer

Interview Answer

1 Answer

0

You split the marbles in triads and you scale the two of them.
1a.they weight the same
2.you take 2 marbles from the last triad and you put them separately in the scale.
If the marbles weight the same then the third one is the heavier else we can find from the scale which one is the heavier.
1b.you take the triad that's heavier and you continue with step 2.

Interview Candidate on Nov 23, 2012

Add Answers or Comments

To comment on this, Sign In or Sign Up.