Name: dasuraga !8GgBtN/zr. 2010-01-06 14:43
What do you guys think are some problems that most all programmers should be able to write in under 5 minutes? For me, I'd guess Hanoi should be an essential one: writing a function Hanoi(char* letters,int number,int to,int from,int temp) to solve the tower of hanoi problem for 3 slots(the letters array has the disc identifiers in decreasing order) You are supplied with the function move_single(char id,int to,int from) that moves the top disc on the to slot to the from slot(assumes it to be possible).