News for hackers. Stuff that matters.
Re:Become a Better Programmer by Taking a Shower by SillyUsername on Thursday April 20, 2023 @03:54PM (#35645379)
If your interview has traditional comp sci academic questions instead of practical then perhaps avoid that company (unless it is academia).

What they should be asking you is to show the most optimal way to reverse the array, which is to find a popular highly optimised library and use that, one that is also likely to be far less buggy.

Algorithmic implementation screams academic, practical implementation yells experience.

Re:Become a Better Programmer by Taking a Shower by JohnFen on Thursday April 20, 2023 @05:54PM (#35646947)
> What they should be asking you is to show the most optimal way to reverse the array, which is to find a popular highly optimised library and use that

While I don't think those questions should be part of the interviewing process, I disagree with this. Answering "use a library" is not giving an indication of your skillset. I would consider that failing answer. I'd prefer to see someone try to work the answer out and get it wrong instead, because it's the working-out process that gives you any insight into the candidate's skillset.

Re:Become a Better Programmer by Taking a Shower by SillyUsername on Friday April 21, 2023 @03:30AM (#35650770)
I was asked one of these questions at a publicly owned organisation about 10 years ago, I told them I could do it, but I'd use a specific Apache library, and answered on how the library is used, I also have a second choice of library and illustration.

I failed to get the job.

That company has a massive staff turnover, and as well as other high profile foul ups, has recently been responsible for updating the details of hundreds of benefits recipients with identical address values.

I also had this same experience with another company 15 years ago that is what recruiters call evergreen (always hiring). This is because they have similar archaic practices and I've been told the turnover is because they have a huge mashup of custom code and implementations. Difference of experience Vs academic in my small circle :)

Re:Become a Better Programmer by Taking a Shower by ralferoo on Friday April 21, 2023 @06:44AM (#35651949)
> What they should be asking you is to show the most optimal way to reverse the array, which is to find a popular highly optimised library and use that, one that is also likely to be far less buggy.

The most optimal way is not to reverse the array at all, but instead index it in reverse later in the code when it's used.

Re:Become a Better Programmer by Taking a Shower by loa_in_ on Friday April 21, 2023 @12:34PM (#35656267)
I believe the better answer is "give me more detailed, and better yet, real context".