7 ms·
that doesn’t really matter. leetcode interviews are about producing the solution the interviewer expects.
by b20000 4y ago
that doesn’t really matter. leetcode interviews are about producing the solution the interviewer expects.
- dogbox 4y agoWhat kind of interviewer expects a solution that's not only incorrect, but also woefully inefficient?
- actually_a_dog 4y agoNobody expects that, obviously, but such solutions do occasionally get accepted (by humans). Beyond a certain basic level of competency, a lot of interviews, including LC-based ones, are about how good the candidate is at story telling and/or explaining their thought process.
- teraflop 4y agoSo you're saying the interviewer expects a wrong solution, and the wrong solution they expect is the same wrong one the AI generates (which happens to be twice as long as the correct version), and the interviewer doesn't bother to run the tests?
- whimsicalism 4y agoHacker News doesn't generally really make that much sense on topics adjacent to leetcode or discussing tech interviews, best to stay away.
- dogbox 4y agoThis thread is making me feel like I'm taking crazy pills! Staying away is great advice.
- autotune 4y agoExactly. Would I use this for actual production code in any way right now? Probably not. In an interview setting where the interviewer thinks testing candidates through Leetcode is a good strategy? Maybe just to see if I could use it to make it to the next round.
- nine_zeros 4y ago> that doesn’t really matter. leetcode interviews are about producing the solution the interviewer expects. This. In an interview, it doesn't matter. The interview process only selects for correct results, not for an individual's ability to solve problems.
- teraflop 4y agoBut this is a demonstration that OpenAI doesn't produce correct results, which becomes obvious as soon as you hit the "Submit" button on Leetcode.
- saxonww 4y agoMaybe I've just drunk the koolaid, but as someone who has given these 'coding challenge' interviews, I: - Do go into them expecting to see a certain solution. - Do not penalize people for giving me a different one, if it works. I think that's awesome, personally. - Do ask people if they can think of additional test cases vs. those provided, and I penalize if there's obvious ones that they don't come up with, or if they just give me a bunch of variations of what we've already provided. - Do consider whether people actually read and/or understood the prompt (I read it to them). If I've asked you to write a function that returns a boolean, and you write a function that prints 'true' and doesn't return anything, and after some gentle prodding you don't get it, then you didn't solve the problem. - Do ask for you to talk through your solution and approach so I understand how you're thinking about the problem. I need to know whether you can code, and more importantly that you understand why you're doing what you're doing. I can't ask your prior employer. Not everyone has open source contributions or a portfolio of work they can show me, and no, I am not going to just look at your resume and say "well, they worked for a software company before so clearly they know what they're doing." I prefer take home exercises, where there's less manufactured pressure. I think they also lend themselves to a wider variety of challenge vs. the online 1 hour test using coderpad or something, meaning you may be able to ask something more appropriate for the role. But this approach upsets people as well.
- whimsicalism 4y ago> But this approach upsets people as well. Ultimately you have to realize that any process that is gating people from an opportunity & resources is going to upset people. People have an amazing capacity to make up elaborate reasons and narratives for things to be unfair, especially when there is a group of them.
- haswell 4y ago> I need to know whether you can code, and more importantly that you understand why you're doing what you're doing. I haven't gone through the interview process since 2013, so I might be a bit behind here, but are these challenges still happening under pressure in a highly time constrained environment? Because if they are, and if you interview me, you will probably not learn whether or not I can code, or if I know why I'm doing what I'm doing. I know this is a subject that has been discussed to death, but all this tells you is whether the candidate is good at high pressure coding exercises. I'm on sabbatical and half considering semi-retirement, but economic pressures are pushing me in the direction of seeking work. If there's one thing I do know, it's that I will pass on companies who insist on this kind of exercise. Let me take it home, and that's a different story. I know that not everyone will be happy with every approach, but time and time again, I've found the high pressure exercises useless, and that includes when I'm interviewing candidates. One dev team at my former company passed on me because I didn't do well in one of these high pressure exercises. A different team picked me up (they didn't believe in this type of exercise), and I spent over 8 years at the company and was known as a top performer.
- d0liver 4y agoIf all they expect are passing test cases, then just use canned values in your code to make the tests pass. This is way more performant and even more efficient to write.
- teraflop 4y agoPart of the point of this style of challenge is that you're not given all of the test cases up front. And even if you are, you generally can't come up with those "canned values" without actually figuring out an algorithmic solution. As I said, some of the test cases for this particular problem can be strings up to 100,000 characters long. Do you really think it's faster to solve those by hand than to come up with a correct algorithm to do it for you?