Qualcomm

www.qualcomm.com
Engaged Employer

## Interview Question

QCT Modem Test Engineer Interview San Diego, CA

# You have 2 buckets in a room and one bucket has 17 Red

balls, 19 Green Balls, 21 Blue Balls, 23 Yellow Balls. You are blindfolded and you need to pick one ball at a time and put in the bucket#2. You should stop at a point where you are confident that the color of the ball you are putting in already exists in the bucket#2. When would you stop?

5

Worst case - you stop at the 5th chance because after 4 different colored balls the 5th ball color has to repeat.
Best case - you stop at the 2nd chance because you get the same color ball after 1st.

Interview Candidate on Apr 13, 2012
0

But it asks when will you be confident about that. So I guess it is after the 5th ?

Jason on May 27, 2012
3

But what if all of the first 4 you pick are of the same color? Then the 5th may not be already in bucket 2.
Going by that logic, I feel you'll have to pick (23+21+19+1) = 64 balls in the worst case, where the first 23 you pick are all yellow, the next 21 are blue, next 19 are green and the last one is red. What do you guys think?

Gautam on Jun 24, 2012
0

Gautam, your answer would have been correct if the question would have been - "You should stop at a point where you are confident that 'all four' color balls you are putting in already exists in the bucket#2

Sam on Aug 16, 2012
0

I think 24 balls...The highest ones + 1

0

I think 3 is the answer.

HanaAsha on Dec 19, 2012
2

64, by worst case

wenhao on Feb 28, 2013