I was asked the infamous rectangular cake question during a job interview:
How would you cut a rectangular cake into two equal pieces when a rectangular piece has already been cut out of it? The cut piece can be of any size and orientation. You are only allowed to make one straight cut.
This was terrible for two reasons:
- I think certain types of puzzle questions that have an "aha" answer don't show anything about the candidate. If you've heard the question before, you can fake working through the answer. If you haven't, the problem space is completely defined in the question, which means that the candidate doesn't really have a sensible way to work through the problem asking clarifying questions the way someone would with a real requirement.
- Although I immediately came up with a valid answer given all the constraints specified - "make one straight horizontal cut along the height of the cake so that the resulting slices are of equal sizes", this wasn't the answer the interviewer wanted, so I stood in near silence for a couple of minutes and then drew the "correct" answer on the board.
Although I got a job offer from this interview, the stupidity of this question and the general zealotry of the interviewer put me off working for the company, so I guess this question was useful for me to help decide not to work there!