Maven Securities Interview Question: One bag contains 13 white and... | Glassdoor.co.uk

Interview Question

Junior Trader Interview London, England

One bag contains 13 white and 15 black marbles. Outside we

  have 28 black marbles. Every time I pick two marbles from the bag and place back one, whose color depends on the combination of the marbles I put out. Combos : OUT: 1 black-1 white IN : 1 white OUT: 2 blacks IN : 1 black OUT: 2 whites IN : 1 black What is always the color of the last marble remaining?
Answer

Interview Answer

2 Answers

0

1 white marble.

In order to end up with all black marbles, you need an even number of white marbles in the bag at some point. (So you can remove them all in pairs and return black marbles).

This means you need an odd number of white marbles outside the bag.

You start with 0 white marbles outside the bag. However, the number of white marbles outside the bag will always be a multiple of 2. You only ever add 0 or 2 white marbles to the marbles outside the bag (1 b 1 w = return 1 w = 0 white marbles. Remove 2 w marbles return one b = + 2 white marbles outside the bag)

Since it is impossible to ever have an odd number of white marbles outside the bag, it is impossible to ever have an even number of white marbles inside the bag. Thus, you can rule out the possibility of there being 13 white marbles outside the bag. Leaving only 1 possibility. That is 12 white marbles outside the bag and 1 on the inside. The last marble is always white

nollag_trd on 3 Aug 2018
0

I agree with nollag_trd, but to put it more succinctly:

White marbles are only ever removed in pairs (if a single white is drawn, it's put back).
There are an odd number of white marbles in the bag.
Hence, the last white marble will never be removed.

Anonymous on 18 Jul 2019

Add Answers or Comments

To comment on this, Sign In or Sign Up.