Live data from Hacker News

Python coding interview challenges

github.com

121–130 of 252 posts

Re: Python coding interview challenges

#121
post #35

I recently tried for the second time to apply to some agency type place. I have 10yrs of coding, worked with big data, have done micro coding( developed protocols for vending machine transactions), done frontend and backend small and large scale. But this place had 3 of these type of challenges that you had 1hr 30mins to complete all of them. I'm sorry, most of this stuff you will NOT find in any job unless its some…

In the same way that nobody ever got fired for suggesting IBM, I imagine there's a lot of HR / tech hiring apeing MS/Google/FB. Even if it makes no sense in their business development context.

Re: Python coding interview challenges

#122
post #90

Earlier quoted context omitted.

No, it's the attitude. Saying "I don't know depth first search" is fine, saying "I'll never need this and by asking it you've revealed what a terrible company you are" is sour grapes.

Not revealed as a terrible company, perhaps, but as a terrible interviewer. If any company were to quiz me on algorithmic basics, it had better explain to me beforehand why it is among the x% of all hiring companies that actually need to roll their own new solutions in the face of so many well-established libraries. That is, before you ask me to demonstrate a depth-first search, you had better explain to me why I'm g…

> need to roll their own new solutions in the face of so many well-established libraries

I'm not defending interview quiz-time, but it isn't (or shouldn't be) about rolling your own solution. It's about understanding concepts. Understanding the basics of time/space complexity are pretty fundamental when designing systems.

Developers frequently encounter hashing and (probably less-often) trees, so I don't see an issue with asking something like "Why/how/when is a hash-based lookup faster than a tree-based lookup?" (as one question during an interview). If a person can give a good answer to this, they'll pretty easily be able to understand the performance tradeoffs of hash vs btree indexes when using mysql (and this same tradeoff in a variety of other situations).

Re: Python coding interview challenges

#123

Earlier quoted context omitted.

> Oh and did I mention the Hacker Rank challenge was being asked before even speaking to a human being about the job? I prefer that a lot more than scheduling a 1 hour phone interview during my workday, to do the same stupid questions over the phone, with someone who can describe neither the job nor the company.

Sure, that scenario is equally broken and happened to me with a big S.V company recently. If the company can't even schedule an interview with someone on the actual team then I'm probably not interested in the company and can and have cut the phone interview short upon learning that.

It's not enough to be on the team, the person has to be able to talk, not a mute engineer.

Re: Python coding interview challenges

#124
post #90

Earlier quoted context omitted.

No, it's the attitude. Saying "I don't know depth first search" is fine, saying "I'll never need this and by asking it you've revealed what a terrible company you are" is sour grapes.

Not revealed as a terrible company, perhaps, but as a terrible interviewer. If any company were to quiz me on algorithmic basics, it had better explain to me beforehand why it is among the x% of all hiring companies that actually need to roll their own new solutions in the face of so many well-established libraries. That is, before you ask me to demonstrate a depth-first search, you had better explain to me why I'm g…

> "before you ask me to demonstrate a depth-first search, you had better explain to me why I'm going to need to be doing that instead of just writing an SQL query and tweaking an index"

How I am going to ask you to tweak an index, if you don't know how to browse a tree? Although I would have asked you about B+ and B* trees, the ones used to index a database. There are differences in those trees and you need to know them in order to decide which one is a better option to improve the performance of the queries. Obviously this improvement means nothing for a small startup, but image the impact it has in a company as Google.

I think the point is that a lot of interviewers make those questions because big companies do them. But there is a reason why they do them. Obviously I would prefer the candidate that knows the answer over another one that also does the job but doesn't know the answer.

Re: Python coding interview challenges

#125
post #61

Earlier quoted context omitted.

> I'm a kick-ass get-things-done full-stack web engineer. And modest, too. If an engineer gave me your answer ("I never learned the principle because I never had to") I would know they aren't a fit for my team.

I think you are looking at this wrong. I have zero problems with someone presenting themselves this way and would definitely consider hiring the person. Here's reality: Someone who knows their stuff is able to dive into details of their work in a way that an impostor can't. My response to the above would be to have the person bring in some of their work and take an hour or two to take a deep dive into it. I want to s…

The problem with your approach is that it excludes anyone who spends most of their time writing code for a business. I legally can't provide you with the code that I have written over the last several years. You're limiting your applicant pool to people who have been paid to work on open source, freelance web developers, and people with very little life outside of work.

I agree that puzzles aren't all that great of a measure of ability, but at least anyone can do them without writing about thorny legal issues over IP or spending all of their free time on spare projects.

Re: Python coding interview challenges

#126
post #109

Earlier quoted context omitted.

In that 2% of the cases where you have to come up with something new, I don't really think that knowing pretty much any of this would help. You are storing a lot of information that will probably never be used. On the other hand, knowing how to come up with the solution. Knowing where to ask, what books to read or what people to ask, seems like a more important skill.

You are OK with not knowing how to invent, innovate, push the envelope, etc because you don't need to in order to collect your paycheck? Seems sad! Where is your passion for the craft?

That's not what he said.

Re: Python coding interview challenges

#127
post #61

Earlier quoted context omitted.

> I'm a kick-ass get-things-done full-stack web engineer. And modest, too. If an engineer gave me your answer ("I never learned the principle because I never had to") I would know they aren't a fit for my team.

I think you are looking at this wrong. I have zero problems with someone presenting themselves this way and would definitely consider hiring the person. Here's reality: Someone who knows their stuff is able to dive into details of their work in a way that an impostor can't. My response to the above would be to have the person bring in some of their work and take an hour or two to take a deep dive into it. I want to s…

> My response to the above would be to have the person bring in some of their work and take an hour or two to take a deep dive into it.

So another interview and another day off work? Another set of interview approaches/questions that immediately eliminate people who don't spend their free time doing the same thing they do at work 8+ hours a day?

This is not solving the problem.

Re: Python coding interview challenges

#128
post #18

Earlier quoted context omitted.

How often have you had to code up solutions to any of these challenges in the last two decades? These sort of challenges are great for learning some of the theory behind computer science and getting you thinking, but they're not a useful part of the interview process imo.

Exactly. I am pretty sure there is a (well tested) library out there to do those things.

At some jobs we make the libraries you use to solve those problems. These interview questions test very basic CS concepts and many of them are essentially just extremely watered down versions of real life problems. I can teach a dev how to Google for libraries, I can't teach him basic CS concepts. I would much rather hire for the latter.

In fact this whole thread makes me uncomfortable. I wouldn't want to work with anyone who gets nervous when told to reverse a linked list.

Re: Python coding interview challenges

#129
post #68

Earlier quoted context omitted.

I was going to agree with you, 98% of my career has been "google for a library, then use or tweak". It's RARE we ever actually do anything "new". However there ARE companies that do, and every once in a while YOU may have to do something new. In those cases it's good to make sure you have a foundation to build on. I have 4 books in the "The art of computer programming" series on my desk. They've been more or less dec…

In that 2% of the cases where you have to come up with something new, I don't really think that knowing pretty much any of this would help. You are storing a lot of information that will probably never be used. On the other hand, knowing how to come up with the solution. Knowing where to ask, what books to read or what people to ask, seems like a more important skill.

Even if something represents 2% of your cases, if no one at a company or on the team has algorithmic problem solving skills it will represent more than 2% of your development time.

Re: Python coding interview challenges

#130
post #125

Earlier quoted context omitted.

I think you are looking at this wrong. I have zero problems with someone presenting themselves this way and would definitely consider hiring the person. Here's reality: Someone who knows their stuff is able to dive into details of their work in a way that an impostor can't. My response to the above would be to have the person bring in some of their work and take an hour or two to take a deep dive into it. I want to s…

The problem with your approach is that it excludes anyone who spends most of their time writing code for a business. I legally can't provide you with the code that I have written over the last several years. You're limiting your applicant pool to people who have been paid to work on open source, freelance web developers, and people with very little life outside of work. I agree that puzzles aren't all that great of a…

> You're limiting your applicant pool to people...with very little life outside of work.

Imagine that.

If your company exists solely to write CRUD apps in whatever JavaScript framework came out in March, you don't need to spend hours doing a deep dive into someone's side project todo list app. Unless, of course, you're looking for someone who will work 16 hours a day, 6 days a week, for one tenth of one percent.

Post reply on HN