Intel Corporation

www.intel.com
Engaged Employer

## Interview Question

Interview Columbia, SC

# Conversion from hexadecimal to binary. The brain teaser

: You have two cups, one that can hold up to 5 quartz of water and the other 3 quartz. Get me to 4 quartz of water.

1

Staring with 2 empty cups - Pour water until full into the 5 quartz cup - Pour water from 5 quartz cup to 3 quartz until full - Toss water out of 3 quartz cup - Pour remaining to quartz into 3 quartz - Pour water into 5 quartz cup until full - Pour water from 5 quartz cup to 3 quartz cup until full

Anonymous on Jun 21, 2014
4

Fill 3 quartz cup with water, pour it into the 5 quartz cup. Now 5 quartz cup is 3/5th full Again fill the 3 quartz cup and fill the remaining of 5 quartz cup using that. Now 5 quartz cup is full, and 3 quartz cup has 1 quartz water. Empty the 5 quartz cup and pour the 1 quartz water from 3 quartz cup into the 5 quartz cup. Fill the 3 quartz again and pour it into the 5 quartz cup which now has (1+3) = 4 quartz

Gautam on Sep 3, 2014