In my experience interviewing candidates for Amazon(1), there is definitely a talent shortage. We get a surprising amount of applicants that can't write a basic program. Personally, I reject 4/5 of all applicants at the phone screen because they couldn't write a very simple program.
I use a collaborative code editor so I can see what the person is typing, and I don't give trick problems. I pose the question, and ask them to think about it before coding. Once they've landed on an acceptable solution, I ask them to write it up. 80% of the time it's broken or they can't finish it (these solutions should be 20 lines or fewer). On at least one occasion the answer was copied directly from stack overflow :\.
Trick questions are all the rage, but I'm not convinced that they actually highlight a competent developer. The problem (in tech, not specifically at Amazon) is we're all trying to emulate Google, and since they ask brain teasers then we have to ask them too, because it must be the one true way.
In summary, I think there is both a shortage of good devs, and contrived puzzle questions are not actually an good for evaluating a candidate.
(1) These views expressed are my own, and not necessarily the views of Amazon or its employees. Disclaimer added at my own discretion, not due to any corporate policy.
Amazon has a terrible reputation which may distort who shows up. I have done conducted plenty of interviews for a few company's and having a solid reputation drastically improves the quality of candidates show up.
EX: Microsoft has middle of the road reputation and I know people that would literary consider with them at 120k to be a better option than 140k at Amazon.
There are certainly people who apply to Amazon after having made a couple websites, thinking that Amazon is just a website so they're qualified. What they don't see is all of the intense engineering that happens to keep that website running. A very small portion of our engineers ever write HTML.
Amazon does have a reputation of being cheap (and it's well-deserved), which is probably causing a lot of great devs to avoid the company entirely. That would skew the numbers in favor of less talented devs. However, I don't believe our rejection rate is higher than the industry average. 80% rejection at phone screens is pretty standard.
Edit: Also, for your particular example, Microsoft was _way_ better benefits than Amazon and a better office environment. I can't comment on pay, since I don't know their typical payscale.
My personal experience with amazon recruiters has been poor. At a college career fair they basically shoved off anyone who was looking at internships (while treating full time like they were gold). I've never interviewed with them because I really don't care about a company that won't give me the time of day if it isn't aligned with their immediate needs.
The underlying problem in tech hiring is that it is difficult to assess candidates in an interview format. Many of the skills and personality factors that make someone a success are dependent on context. Transplanting an engineer to a new context is uncertain, even for putative rock stars.
Many of us have presumably seen our share of brilliant people flame out because they could not adjust to the ambient value system, and figure out how to get the right things done. Often these people flourished in a prior context: school or another company with more or fewer constraints.
Assessing that context match is hard. The most successful way is to have a mutual trial period (ex: internship). Failing that, in interviewing for a full-time position, the closest you can get seems to be by trying to simulate what it'd be like to work together. That's why you try to throw them at coding exercises or difficult problems. "Brain teasers" are silly but coding challenges where you see how far they can go with some direction are actually pretty useful. They give you a large dynamic range within which to quicky hone in on someone's current skill level. More interesting than their current skill level is how quickly you think they can progress, and so that's what you try to simulate in an interview.
That is definitely an underlying problem. Interviews are too short and too stressful to accurately show how good a candidate is.
I'm not particularly good in interviews because I get nervous and stumble over my words. It is not at all like a real working environment, so I think any conclusions you draw from one are necessarily flawed. I recently read about Heroku's interview process, and I think it's great that they can invest so much in evaluating their candidates. They give each new candidate a project to work on and make a hiring decision after it's been completed. (See http://www.craigkerstiens.com/2011/12/02/how-heroku-works-hi...). I also think it's unsustainable as their company grows but I would love to be proven wrong.
People perform differently when they are being watched not to mention interviewed. Some deviate substantially.
Also, that collaborative editor might not fit their fingers due to a habit.
Even more: often people just don't like each other and the interviewees feel that, get nervous and perform poorly. I know someone who was dismissed as completely unqualified on the phone screen interview where I work and then Amazon hired him and he's quite successful there.
Nobody should be asked brainteasers in a Google engineering interview. I have no idea where those bogus "20 Google interview questions" lists with stupid puzzles come from. But really the interviews are supposed to cover things like coding, algorithms, and systems design.
I use a collaborative code editor so I can see what the person is typing, and I don't give trick problems. I pose the question, and ask them to think about it before coding. Once they've landed on an acceptable solution, I ask them to write it up. 80% of the time it's broken or they can't finish it (these solutions should be 20 lines or fewer). On at least one occasion the answer was copied directly from stack overflow :\.
Trick questions are all the rage, but I'm not convinced that they actually highlight a competent developer. The problem (in tech, not specifically at Amazon) is we're all trying to emulate Google, and since they ask brain teasers then we have to ask them too, because it must be the one true way.
In summary, I think there is both a shortage of good devs, and contrived puzzle questions are not actually an good for evaluating a candidate.
(1) These views expressed are my own, and not necessarily the views of Amazon or its employees. Disclaimer added at my own discretion, not due to any corporate policy.