News for hackers. Stuff that matters.
Re:Hiring Is Broken by Merad on Thursday January 17, 2019 @01:07PM (#18932969)
> I can't remember Djikstra's algorithm either, but I would happily try and write a 15 line brute force recursive maze solver in an interview.

You'd fail the interview. The type of interviewers that ask this style of question are never interested in seeing the the naive brute force approach.

Re:Hiring Is Broken by EduardoBautista on Thursday January 17, 2019 @01:13PM (#18933026)
My experience has been different. Usually the best thing to do is to write the naive approach first and then let the interviewer guide you towards what they think you could improve.
Re:Hiring Is Broken by Rooster61 on Thursday January 17, 2019 @01:32PM (#18933197)
This.

Implement -> Evaluate -> Refactor

I'd rather have someone who could caveman the first approach, recognize the inefficiencies, and improve the execution than someone who rattles off a memorized algorithm to a common problem.

If the interviewer is wanting the eloquent solution right out of the gate, then the manager might be hiring for the wrong position.

Re:Hiring Is Broken by chooseaname on Friday January 18, 2019 @12:11PM (#18940776)
This works best when you've formed a rapport with the interviewer. If you haven't then you've already bombed.
Re:Hiring Is Broken by devxpy on Thursday January 17, 2019 @03:04PM (#18934084)
Have you ever tried to implement the KMP (https://en.wikipedia.org/wiki/Knuth%E2%80%93Morris%E2%80%93P...) pattern matching algorithm yourself?

I tried doing it -- even with the knowledge of how it works, it took me at least a day to get to an acceptable implementation.

Re:Hiring Is Broken by EduardoBautista on Thursday January 17, 2019 @04:13PM (#18934687)
OK, so you are just going to assume that any interview you can't pass is broken?

There have been interviews I have failed and instead of blaming the interviewers I took the time to actually study the problem I was given. This has helped me become a better programmer.

Re:Hiring Is Broken by devxpy on Friday January 18, 2019 @04:17AM (#18938069)
No, i was just presenting a counter argument. I never had to actually implement KMP outside of uni though.

Interviews that require extra knowledge outside of what the job actually asks for are definitely broken.

Re:Hiring Is Broken by throwawaymath on Thursday January 17, 2019 @02:08PM (#18933561)
That has not been my experience as an interviewee. Implementing the naive solution for small n has been well received in my interviews, and from there (imperfectly) optimizing it is a collaborative experience.

I don't doubt you've experienced differently. But if you have, I think it's likely the interviewer, not the question. Lots of interview questions can be abused, not just basic algorithms and data structures questions.