Earlier quoted context omitted.
No, it's a pretty good interview question because it tells me if somebody's instinct is to reinvent the wheel or not. What I didn't expect was how many people couldn't say how a wheel even works.
People are not generally answering interview questions based on instinct, but rather based on what they think the interviewer wants to hear to get the job. I would have interpreted this is as a leetcode style algo question and started by treating it as such, even though IRL my first instinct would be "get a lib that does it". Awful, awful strategy.
I prefer fizz-buzz as a question because it is obvious there isn't a library. It is also a problem you should be able to do in an interview. It has enough weirdness that there is no best answer, despite having several workable paths you could try.