Software engineers who are about to begin their careers are very weird creatures. They read a blog about a very hard problem they cannot solve, it affects their self esteem and self worth. They become very easy to control. Strange thing is, the smarter you are, the more it happens to you.
Don't believe me?
Look at the standard interviewing process for hiring engineers at popular companies and an interviewing preparation industry that feeds on this weakness.
If I wrote a book on programming interviews or built a subscription site for helping programmers prepare for it- First, I would write so many blogs and flood popular forums with content that creates self doubt in aspiring programmers who are all my potential customers. Then offer "One weird trick that gets you a job at popular company XYZ". After all, Internet is a great medium to self-promote. This is also the same sales technique behind how enterprise software is sold. Remember "Nobody ever got fired for choosing IBM".
The next thing I would do is look at the hiring pipeline and see how do I get an official endorsement? Oh wait, I know this HR person, let's get recruiters recommend my site in the official interview invitation email.
This is exactly how this interviewing problems madness got official. Each interviewer is outdoing the other one in picking a problem that cannot be solved in an hour. Now there are universities that offer a complete course on programming interview preparation.
Now that it's the official hiring process, the students coming out of universities have wrong expectations or no expectations about what the job of a programmer or a software engineer really is. They are just seeking validation from a brand more popular than them. This explains why most of the engineers and programmers who are very smart end up working for the marketing or sales guy who does not have the challenges of self doubt or already overcome such issues.
Don't believe me? Follow your hierarchy to the top.
I am not putting down marketing/sales people but it is a general understanding that engineering is a much harder job. Marketing and Sales require years of experience and making right choices consistently. It needs persistence, people skills and other qualities compared to problem solving intelligence.
The same ones who believe everything they read on the blogs without much of critical thinking, will be choosing the next tool for your project and its architecture. They tell me not to worry, they use the same tool at "google" or worse, if you do not use this tool, your company is using legacy technology. But I digress.
Whatever happens in Silicon valley, rest of the world copies. I heard the process is much more crazy in China. An international masters student from china told me that, the problems asked here in big companies are so much easier compared to questions Chinese companies ask.
It's about time this needs to be dealt with.
First, know the reasons why people ask very hard programming challenges in the interview.
Asking hard questions works and it brings respect for all the candidates that are actually hired this way. Easy come easy go. If people worked hard for something, they would want to keep it for a while and are afraid to lose it. So it works either way to retain people.
The interviewer/s do/es not like you based on first impressions. Something in your resume could have triggered a value judgement or a compete signal instead of cooperate signal. The only way one can recover is, solve the very hard problem.
The person interviewing does not have the maturity to hire, they are looking for a strong sign from the candidate (Check if you can convert water to wine or walk on water). I personally believe this is the most common case.
They are testing the psychology.
There is a very small percentage of people who become more focused when faced with a challenge. There are also a percentage of people who would want to jump off the building when faced with a challenge. The only way to figure this out is by giving a challenge that cannot be solved with in 1 or 2 hours and look for signs of strength.
A reason to hire immigrants on a visa with out getting into trouble with immigration department. Look at our interviewing process only 1% of the candidates get through.
If you are a hiring manager or a senior dev in a software department, you should be part of the solution and not the problem.
First ask yourself, can people in your current team solve this problem in an hour? If not, then do not let such questions be posed to aspiring candidates.
Figure out a better hiring approach for your team or company and set right expectations for interviewers. Coach people how to interview and select only few experienced people who will do the interviewing.
Take end to end ownership of hiring and fix any leaks in pipeline. Make hiring personal. If not, your success depends on something else outside your control.
If you are an aspiring programmer or engineer, you should first fix your framework of thinking and build a constructive foundation based on your skills, capabilities and potential.
If your goal in life is to get a job at a popular company, you will eventually achieve that goal, but you can aim higher and achieve a greater purpose too.
Replace "practice ***code interview questions" with "Build something useful".
Focus on all round development. Improve your social skills, communication skills, writing skills, speaking skills. Research a list of 1000 problems that technology can solve and how you might be able to contribute.
Do something different and stand out. Don't be a zombie and try the same thing that a million other people are doing. If you are brainwashed so much, not even the best mentors will be able to align you and show you the road not taken that you might make a difference. A great man in our industry called for "Think Different". Try that.
Whenever I hear a young masters student tell me about how they solved 500 ***code programming challenges, the only thing I see is that's how deep this person's need for approval is. It may take so much effort to un-brainwash them if someone were to take a person like that on their team and be responsible for grooming them. Many people may not want to handle that much emotional burden.