When I interviewed graduate programmers I used to ask them to write a Fizz Buzz app, in any language or pseudo-code they liked.
[Fizz Buzz : print the numbers 1 to 100. If the number is divisible by 3 print 'Fizz' instead, divisible by 5 print 'Buzz' instead and divisible by both print 'FizzBuzz' instead]
No graduate got it 100% right. One who claimed he had a Masters could not even start...
I hired the one who got very close, was very disappointed he got it wrong and was genuinely interested to know how to fix it.