5 ms·
I recently interviewed a candidate with a degree in computer science. He was unable to explain to me how he would have implemented the Fibonacci sequence withou
by Beretta_Vexee 2y ago
I recently interviewed a candidate with a degree in computer science. He was unable to explain to me how he would have implemented the Fibonacci sequence without chatGPT.
We never got to the question of recursive or iterative methods.
The most worrying thing is that the LLM were not very useful three years ago when he started university. So the situation is not going to improve.
- dherikb 2y agoWell, I found these candidates long before ChatGPT
- iddan 2y agoI’m 10 years in software and was never bothered to remember how to implement it the efficient way and I know many programmers who don’t know even the inefficient way but kick ass. I once got that question in an interview for a small startup and told the interviewer: with all due respect what does that have to do with the job I’m going to do and we moved on to the next question (still passed).
- dijksterhuis 2y agoi’m around 10 years as well and i can’t even remember how the fibonacci sequence progress off hand. I’d have to wikipedia it to even get started.
- lupusreal 2y agoThere's nothing wrong with that. But once the interviewer tells you that the next number is the sum of the previous two, starting with 0 and 1, any programmer with a pulse should be good to go.
- sarchertech 2y agoYou don’t need to memorize how to compute a Fibonacci number. If you are a barely competent programmer, you should be capable of figuring it out once someone tells you the definition. If someone tells you not to do it recursively, you should be able to figure that out too. Interview nerves might get in your way, but it’s not a trick question you need to memorize.
- JaumeGreen 2y agoBut I'm sure there would be some people that given the following question would not be able to produce any code by themselves: "Let's implement a function to return us the Nth fibonnaci number.To get a fib (fibonacci) number you add the two previous numbers, so fib(N)=fib(N-1)+fib(N+2). The starting points are fib(0)=1 and fib(1)=1. Let's assume the N is never too big (no bigger than 20)." And that's a problem if they can't solve it. OTOH about 15 years ago I heard from a friend that interviewed candidates that some people couldn't even count all the instances of 'a' in a string. So in fact not much has changed, except that it's harder to spot these kind of people.
- jstummbillig 2y agoBut it is. Some knowledge and questions are simply increasingly outdated. If the (correct) answer on how to implement Fibonacci is one LLM query away, then why bother knowing? Why should a modern day web developer be able to write assembly code, when that is simply abstracted away? I think it will be a hot minute before nothing has to be known and all human knowledge is irrelevant, but, specially in CS, there is going to be a tremendous amount of rethinking to do, of what is actually important to know.
- asddubs 2y agothe point is that it's an easy problem that basically demonstrates you know how to write a loop (or recursion), not the sequence itself
- ghssds 2y agoNot outdated. If you know the answer on how to implement Fibonacci, you are doing it wrong. Inferring the answer from being told (or remembering) what is a Fibonacci number should be faster than asking an LLM or remembering it.
- TeMPOraL 2y ago> Inferring the answer from being told (or remembering) what is a Fibonacci number should be faster than asking an LLM or remembering it. Really? If I were to rank the knowledge relevant to this task in terms of importance, or relevance to programming in general, I'd rank "remembering what a Fibonacci number is" at the very bottom. Sure, it's probably important in some areas of math I'm not that familiar with. But between the fields of math and hard sciences I am familiar with, and programming as a profession, by far the biggest (if not the only) importance of Fibonacci sequence is in its recursive definition, particularly as the default introductory example of recursive computation. That's all - unless you believe in the mystic magic of the Golden Ratio nonsense, but that's another discussion entirely. Myself, I remember what the definition is, because I involuntarily memorize trivia like this, and obviously because of Fibonacci's salad joke. But I wouldn't begrudge anyone in tech for not having that definition on speed-dial for immediate recall.
- IanCal 2y agoThis is just the world of interviewing though, it was the same a decade ago. The reason we ask people to do fizzbuzz is often just to weed out the shocking number of people who cannot code at all.
- brulard 2y agoYep, I still can not understand how programmers unable to do fizzbuzz still have a sw engineer career. I have never worked with one like that, but I have seen so many of them on interviews.
- Beretta_Vexee 2y agoI have seen IT consulting and service companies employ ‘developers’ who are barely capable of using software to generate views in a banking software package and unable to write a line of Java (which was the language used on the project). When the client knows absolutely nothing about it and is not supported by someone competent, they end up employing just anyone. This applies to both construction, IT and probably everthing.
- oneeyedpigeon 2y agoUnless you're also a programmer, it's very difficult to judge someone else's programming ability. I've worked places where I was the only remotely-technical person there, and it would have been easy to fake it with enough confidence and few enough morals.
- genewitch 2y agoIf some interviewer asked me what recursion was or how to implement it, I'd answer, and then ask them if they can think of a good use case for a duff's device.
- brulard 2y agoWhy? It looks like a reasonable interview question.
- swat535 2y agoI suppose it depends on the position, but if your company is building CRUD apps with Postgres and you're asking candidates about Fibonacci, you're wasting both your time and, more importantly, the candidate's time. Instead, you're better off focusing on relevant topics like SQL, testing, refactoring, and soft skills. These "clever" questions are pointless. They either serve to stroke the interviewer’s ego: "Look, I know this CS 101 problem because I just looked it up!", or to create a false image of brilliance: "Everyone here can invert binary trees!"
- brulard 2y agoI don't think the point of the question is "do you even know wha fibonacci sequence is?". If candidate didn't know what exactly it is, I have no problem with that. If I explained to him simply the nature of the sequence and he couldn't code it, I wouldn't expect him to be a worthy addition to the team. Recursion is everywhere, SQL, UI, refactoring, data processing, etc. But I agree you can hire a shitty programmer, because his soft skills are amazing. I worked with people that wouldn't contribute much to the code, but created a culture and improved processes in the company. But you should be aware that you are not hiring for a coding position then.
- genewitch 2y ago> They either serve to stroke the interviewer’s ego that's why i'd ask about duff's device. I often admit i am no programmer or developer, here on HN, and that's true. I've only ever implemented recursion when it's part of the pattern or when "learning" a language. my understanding is that recursion is great for tight, small loops, where you need to do say 0<n<10 loops. But if you can't guarantee the tight loop every time, i.e., if it is a dynamic part of business logic or whatever, then you run the risk of blowing up the stack, or heap, or whatever it is. I don't remember which, and i could look it up; but my point is most developers don't need to know if the stack is at risk rather than the heap if your recursive call ends up being called a lot of times. But i really would ask about duff's; me and a friend came up with a use for duff's device maybe 2005 or 2006, and tested it, and published it as part of a forum argument; but i am curious if anyone else could "come up with one" or "remember one" that isn't the "de-facto duff's device demonstration".
- protocolture 2y agoI interviewed a guy with a CCIE who couldnt detail what a port forward was. 3 years ago.