Cover Image: Free on Pexels by Pixabay
Table of Content
A little perspective
1. The Famous FizzBuzz
2. Array Method Polyfill
3. Calcul...
For further actions, you may consider blocking this person and/or reporting abuse
Thanks for writing this up. Obviously interviewing is broken, but I still take issue that a "correct" solution would rely on the knowledge of the existence of a specific function, i.e. sum in example two. I would hope that reduce or another efficient option would be just as acceptable. If not, it ends up being more about wrote memorization/keyword knowledge than about being able to breakdown the problem. Which is, theoretically, the point of the arduous technical interviews we have at present.
Hello Laurie thank you for reading and taking the time to add to the discussion. I think after reading your comment that maybe the wording of the challenge is not clear. The intent is to actually have the candidate write a sum function since it does not exist on the Array prototype methods like map, filter or reduce. In doing so the candidate should be careful in not overriding a possible future implementation of it - say for example if the method was to get added natively in ES8 or later.
For example if I was asked to add a method to the Array prototype that doubles each number in an array, a simple first step might be:
And [2,4,6].doubles() will return [4,8,12].
Of course, that is the first step and there is more to it to make it more future proof - but hopefully that clarifies the intent.
Let me know if the wording needs to be revised.
Thanks again :)
Ah, I was gonna say, I didn't know that WAS a function on array!
I think this is the line that is a bit confusing
You have been keeping up to date with new stuff in JS but are not sure that sum() is part of the Array prototype methods.
That implies that it might be and you just don't know it? I might say,You have been keeping up to date with new stuff in JS and know that sum() is not part of the Array prototype methods.
I think you are right and that section might need a bit of a revision to be clearer. I will take a stab at it, feel free to propose something as well.
This might be a relevant question to ask
Nice thanks for the contribution. I will take a close look. I really like the wording which sounds like a good user story.
Cheers
Here you go: github.com/h5bp/Front-end-Develope...
Awesome Dan - thank you for the link. Cheers
As a developer, I've served for nearly 2 decades, always javascripting. IMO, all 4 challenges above test the modular arithmetic knowledge of a candidate. Being a direct individual, I would simply ask a candidate if they know what mod does.
I have been belittled by self proclaimed GURU's who know a few tricks (tricks are for kids!) in the interview process so many times that I've felt like the most useless developer who's ever been or will be.
In general, I'd say testing someones coding during an interview process shows how incompetent the interviewer is! Just don't do it!