I got denied three times in the final interview with different FAANG companies for not doing whiteboards fast enough. Not getting them right; I mean not doing them fast enough. I’ve passed some whiteboards too in other interviews so it’s not that I can’t do them. There’s a lot of variation here.
I don't want to hire people who implode with a bit of pressure.
The pressure of whiteboard interviews (mostly negative; of the form "yeah this problem is basically trivial, but I'm not used to coding while talking to a stranger, plus the time requirements just don't smell right and certainly do not reflect real work conditions") are so infinitely removed from ...
The pressure at real jobs (mostly positive: "the problem is somewhat non-trivial, and I know time is kind of tight; but I'm in the flow and in my preferred environment; and at least I know the requirements are legit; so can I triage some good result out of this before the end of the day?").
At least for any job one would want to have.
If this distinction is not intuitively obvious to you - or are quick to characterize any negative reaction to your interview as a matter of the candidate being basically a total limp-wrist at your craft, ready to "implode" at the slightest difficulty -- then really, you have no business constructing interview challenges for people. Not challenges with any kind of a time limit, anyway (these being generally unnecessary, when we think about it).
One simple question I ask is to count the words in a string. It's a warmup question and a way to get the candidate comfortable with the format of the interview and the optimal workflow (discuss requirements, propose an implementation, flesh it out in pseudo-code, translate pseudo-code to something that looks like code).
You certainly don't need rote for that, the algorithm is trivial for anyone who did well in their introduction to programming class.
Either the candidate "gets it" in about 10-15 minutes, or struggles for 60 minutes.
> Not a need that comes up in actual software development.
I'm not sure. Ability to remain calm and code when shit's on fire can be fairly useful skill at some places (the smaller the company, the more valuable it can be). I've did that, coding emergency patches - e.g. to cache some hot paths when we've got unusual traffic that revealed bottlenecks that we've never hit (and noticed) before. Though I'd say it's a fairly different mental experience than coding at an interview.
Also, actually writing code on a whiteboard is a weird skill outside of academic roles. But most places I've seen asked to sketch some crude pseudocode or - better - draw wavy lines and boxes that represent processes and entities, then talk about it (and I think this is fine, whiteboard here is just a convenient tool).
And, of course, requiring to remember some algorithms from memory is a rarely useful skill. I've coded even in quite spartan conditions (right in a server room, with an ancient CRT monitor and keyboard, plain vim running on a 80x25 text console) but even then I had one or two Internet-connected devices that I could've used to look things up. If a candidate is allowed (or, better, even encouraged) to search for anything they want - it's all good, of course.
Outside of education, no one bothers to remember actual algorithms unless they've used them recently - everyone remembers names and key properties, and optionally remember some core principles (and then either just use them because they're already in a library or popular package, or go look for the implementation details).
> Though I'd say it's a fairly different mental experience than coding at an interview.
This is the key. Not all pressure is the same.
Shit on fire at work is not actually personal pressure, it's pressure on the company. And to be clear, shit on fire at work tends to be a metaphorical exaggeration, where an emergency code patch isn't going to save the company from imminent bankruptcy. You're still going to have a job the next day, still going to have a roof over your head and food on the table. And your coworkers already know you and respect your work (if you're competent).
This is vastly different from being unemployed, suffering from profound financial worries about your future, and having complete strangers looking over your shoulder, prematurely judging you in the span of a few minutes, where these few minutes can determine your personal fate.
I've done quite a few emergency fixes over my career, but exactly zero of them were lose-the-job emergencies. Whereas every job interview is a lose-the-job emergency.
I keep myself in the interviewing loop at my company because I actually enjoyed the process when I joined. It was conversations over “executable” solutions. Now, we kick out so many candidates that can’t get a coded, running solution in the 45 minute slot.
I have tried so many times to explain the WILD asymmetry going on. That for us, we just have to interview the next candidate. To them, they have the enormous pressure of “if I can’t do this exercise then I have no income, no health insurance, no security.”