3 ms·
One I've had asked of me before is reversing a string, and then I was asked to re-implement it so that the string is reversed in place. I like this one over fiz
by jgroszko 11y ago
One I've had asked of me before is reversing a string, and then I was asked to re-implement it so that the string is reversed in place. I like this one over fizzbuzz because it doesn't require the candidate to know about the modulus operator. It lets you see how the candidate reasons around memory and edge cases, which come up far more frequently than modulus.
- jotux 11y agoA problem with this is that it's asked so frequently people just memorize the answer.
- trcollinson 11y agoThis seems to imply that you can't learn about a candidate without giving them a problem them had not previously memorized. I have most of the solutions to common problems memorized in a few languages and can complete them on a board or a txt doc. Does that make me less of a good candidate? Or more?
- jotux 11y agoI wouldn't say you can't learn about them but it makes it more difficult. Some people are really good at memorizing and when you ask them a common problem it's not useful -- they will just regurgitate the answer and reasoning without thinking about it. Some people are bad at memorizing and asking them the problem can be useful, since they have to work through it again, and fundamentally you want someone who can take a problem and work their way through it. Really you should just create simple, unique, problems and ask those problems to candidates. It's not as easy as just asking the question you were asked, that you know the answer to, but it will force people to actually show if they're capable of solving problems and explaining their thought process. >I have most of the solutions to common problems memorized in a few languages and can complete them on a board or a txt doc. Does that make me less of a good candidate? Or more? I would say this probably makes you good at interviewing but has no impact on whether I think you would be a good candidate.
- jpindar 11y agoI don't know why people seem to think that you need to use a modulus operator to do fizzbuzz. There are several other ways to tell if one integer is divisible by another.