I suck at whiteboard interviews. I've been in quite a few interviews in the last few years, and for every time there wasn't a whiteboard session, I got a job offer.
When I was an interviewer, I didn't see a lot of value in a blank whiteboard and a bunch of computer science questions. I wasn't looking for the vaguely useful smart people; I was looking for specialists - people who had done the work I need done before. Thus I would ask how the candidate would solve a given problem, and we'd have a discussion about the answer. This discussion allowed us to cover quite a bit more ground in the same timeframe.
As a candidate, I did discover a few strategies for surviving a whiteboard interview:
Talk through your thought process as you're working. Sometimes it's more about process and communication than about the solution.
Use your interviewer as a substitute for Google or Stack Overflow. You know that's exactly what you do when you don't know the answer anyway, and it's exactly what the interviewer does too. Demonstrate that you can find out what you don't know, and engage the interviewer at the same time.
Find out how the problem you've been given represents what the job will actually entail. This will give you an idea of how much you're actually expected to do on the whiteboard.
Don't worry about syntax errors; there's no such thing as a whiteboard compiler.
Start with some pseudo-code, and see if the interviewer wants you to expand it out into something more formal. You'll get a lot more done in the available time.
Shows like The Next Food Network Star, America's Next Top Model and The Apprentice aren't just reality T.V. shows. They're also incredibly long and gruelingly difficult job interviews. Would you put up with a month long interview process where you had to move in with the other dozen candidates for the job?
I've got 2 interviews in Seattle today. I showed up for the first one at 9am, but the fellow said he had it scheduled for 9:30, so could I come back in half an hour? Sure, I said, so I went back the elevator. I suspect that I'd be the only female employee in this small organization. All the restrooms in this multi-story office building have keypads and are locked to keep the rabble out. The interviewer I met briefly doesn't have the code to the ladies room.
I went downstairs and across the street to Tully's Coffee. Their ladies room was out of order, so I waited for the men's to become unoccupied. It was a pleasant wait. They have a living-room like atmosphere, including a grand piano. One of the patrons was playing a fine rendition of 'Ob-La-Di, Ob-La-Da'. Then he went onto 'Something '. Hoorah for the Blue Album. Then I noticed that the men's room had a 'Key at Counter' sign. Crap. I think I'll lean on Starbucks across the street..
Later: Whew. The gal at Starbucks was very kind and let me use their restroom. Mad props to SBUX.
Later: The interview went very well. They're going to send me an offer. Score!