r/programming • • Dec 13 '22

“There should never be coding exercises in technical interviews. It favors people who have time to do them. Disfavors people with FT jobs and families. Plus, your job won’t have people over your shoulder watching you code.” My favorite hot take from a panel on 'Treating Devs Like Human Beings.'

https://devinterrupted.substack.com/p/treating-devs-like-human-beings-a
9.0k Upvotes

1.3k comments sorted by

View all comments

53

u/stay_fr0sty Dec 13 '22

Oh cool! Story time.

I had a Chinese student coding for me at my research job at a US University. It's a pretty sweet gig for a student. They work 20 hours a week and go to grad school for free, plus they get a salary.

This guy would come in late, leave early, chat with his friends, never work late, and IT even caught him downloading movies...not the best worker...but students are hard to fire and I when he actually worked it was usable work so he was still a net plus for me so we kept him for the semester.

Anyway, outside of work this dude was DRIVEN. His dream was to work at Google, Facebook, Amazon, Microsoft...you know the kinds of places with cafeterias, and a dozens of other perks...OH and a bunch of H-1B visas to hand out so foreigners remain in America while applying for their green card.

Every night after work and after school he would go home and work on solving interview exercises from those companies for six hours a night. HOW did he know the exercises? There was a Chinese website that he would visit where people that interviewed at those companies posted the questions they were asked. And of course, they posted the solutions. When this guy went on interviews at the end of the semester, he had literally already seen every single "exercise" that he'd be asked to do. He knew them inside and out, could explain them, could talk about the "gotchas" etc...

His #1 choice was Google. He kicked ass on interviews at Facebook and Microsoft already, but he really wanted Google. He goes in and it's kind of a rigorous process. You get interviewed by a bunch of people and they ALL have to agree to hire you because you'd be a good fit for the company. He was crushing it, until he got to the last interviewer, and older Chinese man.

The older Chinese man asked him to solve a problem, which this student knew of course, and solved it. The older Chinese man says: "You knew the answer already. I can tell. Will you admit it?" The student said he knew he was busted so admitting it would show honesty and he said, "Yes. I wanted to be prepared." The older Chinese guy says "you studying the exercises before the interview means I can't see how you work out a problem because you already know the answers." The interview with that guy ended after the student tried to worm he was back into a "good" interview.

The student comes to me a few days later and says Google rejected me. I think it was this racist Chinese guy. He doesn't want other Chinese working there...he wants to be special, and he told me the story.

Anyway this guy ended up taking a job at Amazon working on algorithm improvements. He says it's boring but it pays well.

I just thought this sub would find it interesting how much people actually prepare for these exercises, and how most companies fall for it. Or maybe they don't "Fall for it" and think it's a good thing?

TLDR: I knew a kid that worked 6 hours a night for a semester on memorizing every exercise given by big companies...he got busted at his dream company, Google, and now works for Amazon.

42

u/versaceblues Dec 13 '22

Lol im still baffled by the fact that people think that practicing the answers to common coding problems is cheating.

17

u/MrJohz Dec 13 '22

I think "cheating" is a dumb word to use outside of school. That said, the purpose of an interview is to see how you respond to different challenges. If the answer turns out to be "I look up the answer online, and reproduce it exactly", then they might be a problem later on when you start working on a project where the answers aren't available online, and you need to come up with some original ideas.

I think part of the problem comes from these leetcode problems where there's usually only one right answer and you just need to figure out the trick. If that's all you're asking, then obviously it makes sense for people to learn the trick beforehand if they can. Which is why I think more interviews should involve challenges that don't have an obvious right answer, but where you can go in different directions and have genuine discussions about tradeoffs - precisely the sorts of coding interviews that this panel seems to be criticising.

→ More replies (3)

36

u/ILikeChangingMyMind Dec 13 '22

I doubt Google uses "common" problems.

This guy knew the answers to obscure problems, because he learned about them from another applicant. That's not him being good at coding, that's him cheating by learning the answers to the test ahead of time.

When you get surgery, would you want the doctor who studied medicine, and only got an 80/100 on his final ... or the one who didn't study, memorized the answers to the tests, and got 100/100?

9

u/sintos-compa Dec 13 '22

I’ve done 4 on-campus interview sessions at Google, they don’t have any special interview questions.

→ More replies (1)

12

u/versaceblues Dec 13 '22

I've done the Google phone screens + interview loop. I also have conducted 100+ interviews at a FANG company.I would say most of the problems where pretty common.

  1. Longest increasing sub-sequence.

  2. Write a parser for finding values in nested json objects

  3. build a async queue of requests.

  4. Find array peak using binary search

  5. Graph cycle detection

I think the only interesting question I had was to create a high level design of an app that gives estimated times that arrival by taking public transit.

This guy knew the answers to obscure problems

Yah they really don't. Going tooo obscure is actually bad practice in interview problem design. Also, any obscure problem will just get leaked immediately anyway.

3

u/Reihar Dec 13 '22

That's also a cautionary tale for the corporate world. People work to increase the metrics to which they are beholden. Have shit metrics, you'll get shit work.

Having obscure not real world scenarios as an exam means that you get people who either are good at that out train for it.

I feel like there is a lot to learn about a company from their interview process.

→ More replies (10)