4 ms·
Would you rather get someone who can do fizzbuzz correctly on a board the first time in 7 minutes or someone who can write it in 1 minute on a laptop incorrectl
by iopq 3y ago
Would you rather get someone who can do fizzbuzz correctly on a board the first time in 7 minutes or someone who can write it in 1 minute on a laptop incorrectly, test it, and fix it in 30 seconds?
I see no value in the "gotcha" of you made a logic mistake since we all make them and there's a reason why we test code
- MichaelZuo 3y agoIf they make 1 'logic mistake' on fizzbuzz then it's likely they'll make 10x, or more, 'logic mistakes' on their actual work. Even with a laptop and all the tooling that makes them 10x better, because the real work will be at least 100x more complex.
- iopq 3y agoI made a mistake in fizzbuzz the first time I did it on a whiteboard because I wrote it in "pseudocode" I wrote if (n % 15) print "fizzbuzz" ... I got away with it because my interviewer assumed it was some kind of shell which means 0 is true I should have written n % 15 == 0 to be absolutely clear what I'm doing note that in Rust this won't even compile: 3 | if n % 15 { | ^^^^^^ expected `bool`, found integer But I don't have the type checker to find mistakes for me when writing on a whiteboard which is not realistic. I can't commit this code because CI wouldn't merge a build failure anyway
- MichaelZuo 3y agoHuh? Did you accidentally share private notes?
- iopq 3y agoNo, I'm saying I've made a logic mistake in Fizzbuzz in an interview because I forgot to put == 0 in the condition. If you think that makes me a bad programmer, that's your problem, I just don't think whiteboard interviews are representative of the pull requests I do after working for several hours on something
- MichaelZuo 3y agoWhat? It seems like you have the problem? I don't think I've ever interviewed anyone like this, so far? The comment is bit too bizarre to puzzle out.