TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Life, the Universe and Technical Interviews

14 点作者 sahlhoff将近 11 年前

2 条评论

tempestn将近 11 年前
I tend to ask what I think is a rather simpler question in most interviews: find the sum of the two largest (most positive) numbers in an array of arbitrary integers. Consider the efficiency of your solution for very large arrays.<p>It is amazing how many seemingly knowledgeable, intelligent people cannot do this. And the vast majority of those who do, do it by sorting the array, efficiency be damned.<p>Actually, I&#x27;d like a bit of feedback here. Is this something any decent developer should be able to do with ease? Should it be obvious that it can be done much more efficiently without running a sort on the array? Admittedly there are minor gotchas with things like the initial conditions, but still, I&#x27;ve been flabbergasted by how few people can even get close to a solution, let alone a bug-free and efficient one.
评论 #8123946 未加载
评论 #8123920 未加载
评论 #8123942 未加载
autarch将近 11 年前
FizzBuzz is a reasonable way to find people who can&#x27;t code. I&#x27;ve been surprised to find people with resumes that appeared decent who couldn&#x27;t complete FizzBuzz even given 20 minutes of time to do it in.