I’m listening to a co-worker perform a phone screen (interview) with a candidate to work at Amazon. I think my least favorite question so far is, “Write a program to generate prime numbers within a range.” If you have an algorithm memorized, it’s cake. If you don’t have an algorithm memorized, it’s a good test for a new programmer (or even some who claim not to be so new), but I still think it’s a pretty cruddy question. (I think I’ve had to use the modulo operator twice in three years at Amazon.)
Worse, though, are interviewers who want a single particular answer. Those are the interviewers who, if you provide a correct answer but not the one wanted, will still ding the candidate for not doing it the preferred way.
This is just painful. I hate having to overhear questions like, “Is there a partcular reason you used a.length() rather than 100? How would this be different if you used an ArrayList? What structure backs an ArrayList? How does it grow dynamically?” Coding over the phone is torture, even worse than coding on the whiteboard. The interviewer can get a sense of how the candidate solves problems, but not how the candidate works. (The truth is, I haven’t been able to keep using a lot of my hard-earned best practices at Amazon because management and the technical teams I’ve been a part of are inculcated in the Amazonian “Not invented here” and “That’s now how we do our { libraries | Scrum | Agile process | scripts}.” The biggest challenges someone faces coming to work at Amazon are dealing with the tradition of tribal knowledge, demonstrated in the dual requirements of conforming to the way things are coded here and handling the common attitude of “You’re stupid if you don’t know what you don’t know, so I won’t tell you.”)
When interviewing in-house at Amazon, I was discouraged from using my external memory to take notes on my interviews, at the time a Palm handheld. It was an endearing device when I was contracting at Kroger and my teammates grew to rely on my notes. After coming to Seattle, the batteries stopped accepting a charge and I fell out of the habit. I’ve been looking for a replacement, something with graffiti, but it looks like the best I’ll be able to swing is a Windows smartphone. My last Windows Mobile device was a T-Mobile MDA which was pretty painful to use, certainly not as good as the iPhone, but at least it did accept written input. I’d love to ask the interview candidate, “Has the Windows Mobile platform gotten any better in the past couple years?”