凯西·穆拉托里:我总能在面试中看出一个优秀的程序员
Casey Muratori: I can always tell a good programmer in an interview

原始链接: https://www.gethopp.app/blog/how-to-conduct-good-programming-interviews

## 重新思考编程面试:超越力扣 许多人难以有效评估程序员候选人。本指南探讨了一种替代传统、通常无效的力扣式面试的方法,灵感来自凯西·穆拉托里(Casey Muratori)的方法。穆拉托里提倡一种“深入挖掘”的方法:深入询问候选人关于*他们*构建的项目,旨在理解他们的推理和技术基础。 他的方法侧重于确定候选人是否*胜任*,不一定能确定他们是否能在特定公司文化中茁壮成长(他承认这更难评估)。关键是让候选人*向你讲解*他们的工作——实现细节、替代方案以及他们将如何适应不断变化的需求。 虽然力扣可以通过测试准备好的问题解决能力来减少误报,但它通常会忽略现实世界的适应能力。本指南建议将深入挖掘的方法与在不熟悉的代码库上进行结对编程环节相结合,以评估候选人的导航技能和协作能力。Linear更进一步,通过付费工作试用期,以候选人处理真实项目为基础,声称拥有96%的留存率。 最终,理解候选人做出决定的*原因*比仅仅看他们是否能解决预定义的难题更有价值。

## Hacker News 讨论:评估程序员面试 一篇 Hacker News 的帖子讨论了 Casey Muratori 的面试方法,重点深入了解候选人的过往项目,而不是像 LeetCode 这样的标准化测试。Muratori 声称这种方法能够可靠地识别有能力的程序员,通过评估他们*讲解*自己作品的能力,从而揭示他们的理解和解决问题的能力。 然而,评论者提出了有效的担忧。一些人指出面试官的技能至关重要——并非所有人都能有效地提问和评估答案。偏见也是一个问题,尤其是在系统设计面试中,先入为主的观念可能会掩盖替代方案。另一些人强调了对签署了保密协议或个人项目有限的候选人来说的困难,以及 LLM 可能在远程编码任务中扭曲结果的潜力。 许多人赞成结对编程的想法,使用像 StringCalc 这样的任务来观察候选人的思维过程和协作能力。一个关键的收获是评估候选人*完成工作*的能力,即在特定技术栈内完成工作,而不仅仅是关注过去的成就。最终,讨论强调了适应性、深思熟虑的面试技巧的必要性,并承认没有任何流程是万无一失的。
相关文章

原文

Contents#

Introduction#

Are you struggling with hiring good programmers? This guide will help you to reliably understand if a candidate is a competent programmer, inspired by Casey Muratori's interview.

TL;DR#

Casey doesn't like LeetCode style of interviews, instead, he follows a drill-down approach where he

  • Chooses a project the candidate has worked on.
  • Asks questions with the goal of having the candidate teach him about his project.

With this approach, he claims he can always understand if someone is a competent programmer, and he has never seen it fail.

Casey's Approach#

According to Casey, two questions need to be answered in an interview

  1. If they are competent programmers.
  2. Whether they will be productive at your company/project.

His opinion is that the second question is much harder to answer, and he doesn't know how to reliably do it, and whether there is a way to answer it.

For the first question, he says that with the process he is following, he can always understand when someone is a good programmer.

The process he follows can be summarized in the following steps:

  • When looking at someone's CV, choose a project they have worked on.
  • Narrow down on something specific from this project with the goal of making them teach you that thing.
  • Try to get as narrow as possible, even to implementation details.
  • You don't have to choose something you are not knowledgeable about, but refrain from guiding them if you know the topic.
  • Ask questions like "What did you do here?", "What other approaches did you consider?".
  • Also ask questions that would change the requirements, like "what if we had to do this faster?".

If they can answer your questions, and their answers come from solid foundations, it means that they know what they are doing. If they can't, then they are not what you are looking for.

In his opinion, one of the benefits of this approach, compared to LeetCode style interviews, is that people are responding to the questions from a place of comfort, which is similar to how they actually work.

Asking someone a question like reversing a linked list could make them uncomfortable. Simply because this is something they haven't done in years. On the other hand, if they are comfortable with this question, it is probably because they have practiced, and this doesn't say a lot about their skills.

Our Take#

We generally agree with Casey about LeetCode style interviews, and that they usually don't indicate how good someone is, but instead, they show how well they have prepared. Which is not very applicable to real life. You can't (always) be prepared for the constraints in a project. Besides, a hash-map is not always the answer 😅.

Benefits of LeetCode style interviews#

To play devil's advocate: difficult coding questions are a way to minimize false positives, with the side effect of having a large number of false negatives. Being able to prepare and apply learned techniques is a kind of problem solving. The ability of problem solving is the most important skill a programmer should have.

Another benefit of LeetCode style interviews is that they are somehow standardized. Standardized processes help large organizations stay consistent.

In our opinion, interviews of this style are not the only way to eliminate false positives. The same result can be achieved with Casey's approach too. After all, how could a candidate fake the reasons behind their project decisions, or struggle to explain how they would improve something they have spent a lot of time building?

What is missing from Casey's approach#

While we prefer this approach from LeetCode style interviews, we think something is missing: A way to understand how adaptable the candidate is to a new codebase.

A different set of skills is needed for jumping into a huge codebase and making contributions, from being able to explain why and how you did something you had spent a lot of time working on.

Our proposed solution to this is to have a pair programming session with the candidate, where they have to fix a bug in an unknown codebase. During this session you can understand:

  • The candidate's approach to new problems.
  • How they navigate unknown codebases.
  • How good they are at spotting mistakes.
  • How good they are at expressing themselves and collaborating.

To get the most from this session you could try to

  1. Have the codebase relatively small to not overwhelm the candidate.
  2. For them to be comfortable, let them share their screen. This way they can use their favorite tools.
  3. Allow them to use AI, since it's a core part of the tools we use nowadays.

Linear's novel approach#

Another quite novel approach to tech hiring we should mention, is Linear's work trials.

At Linear, they were struggling to find the right people for their fast-paced environment following the standard interview process.

For that reason, they decided to do paid work trials, which typically last from 2 to 5 days depending on the seniority of the role. They mention that this approach is working very well for them, and they have achieved, at the time of writing, 96% retention. Everyone has to do them, from engineering to C-level candidates. During the trial the candidates work on a real project.

We also believe that this could be the best way to find the perfect fit, pairing on actual tasks should be the best indicator. Unfortunately, not everyone has the bandwidth or culture to support this.

Conclusion#

In our opinion, Casey's approach to coding interviews is an improvement to the current standard. However, it can be extended to have more certainty that a candidate is a good fit.

Our proposed approach is:

  • One drill-down session on a candidate's project.
  • One pair programming session working on a bug.

We would love to hear your approach to coding interviews and whether you disagree with our views.

Feel free to reach out at X/twitter or email me directly at iason at gethopp dot app.

Finally, after you have made the right hire, you can use Hopp, our own OSS pair programming app, to have an even better onboarding experience. During the pairing sessions, you can guide the new hires by smoothly taking control of their computer when needed and saving them time from learning obscure commands and processes.

PS: Only Grammarly has been used on this post, I decided that I am not going to use AI when putting my views online.

联系我们 contact @ memedata.com