You have stacks of quarters, dimes, nickels and pennies (these represent $0.25, $0.10, $0.05 and $0.01, respectively, in the US monetary system for anyone international). There are an unlimited number of coins in each stack. You can take coins from a stack in any amount and in any order and place them in your hand. What is the greatest dollar value in coins you can have in your hands without being able to make change for a dollar?

$1.19. There are a few ways to think about this, but the easiest is to start with the largest coin – quarters – first and then work your way down. 4 quarters equals $1.00, so we clearly can’t do that – but 3 quarters are ok because that’s only $0.75. Next, we have dimes. Recall … Read more You have stacks of quarters, dimes, nickels and pennies (these represent $0.25, $0.10, $0.05 and $0.01, respectively, in the US monetary system for anyone international). There are an unlimited number of coins in each stack. You can take coins from a stack in any amount and in any order and place them in your hand. What is the greatest dollar value in coins you can have in your hands without being able to make change for a dollar?

How would you test a calculator?

Test the functionality of the calculator’s computing accuracy by evaluating whether inputs provide their expected outputs. Also, test the device’s basic system functions — like the power button, the clear function, and so on, to determine whether you’ll be facing system errors before you can compute anything. Depending on the position for which you’re interviewing, … Read more How would you test a calculator?

Design an algorithm to play a game of Frogger and then code the solution…

The object of the game is to direct a frog to avoid cars while crossing a busy road. You may represent a road lane via an array. Generalize the solution for an N-lane road. “One approach is to write a recursive algorithm that determines when to “wait” or to “jump” to the next lane, depending … Read more Design an algorithm to play a game of Frogger and then code the solution…

Imagine you have a closet full of shirts. It’s very hard to find a shirt. So what can you do to organize your shirts for easy retrieval?

There’s no one answer to this. The interviewer wants to test the interviewee’s imagination and creativity with problem solving. We feel like reader “Dude” might impress a Google interview with this answer: Organize them according to types of clothes like a HASH and then organize each type into a 2-3-4-Tree or RedBlack Tree.