@Unixbigot For job purposes I don't think having an exam style coding interview is useful*. I want to know how you approach problems, how you work with people and get requirements and adapt to problems. If the tool fails you want resources do you employ? If the magic button doesn't work can you work past that or do you just keep pushing it to see if the magic will happen**.
I've bombed a coding interview because I missed something, went the wrong way and ran out of time. I wouldn't have hired me after that, but also that's an unrealistic scenario and the time pressure is not useful. In practice going the wrong way sometimes gains you understanding that leads to better results, filtering that out in interviews seems bad.
The other thing that makes giving a code interview challenging is "I know exactly what needs to be done because I've seen this before, they should do that" when there are many valid solutions and the idea is not to replicate what I would do, it's to see that they can work towards meeting requirements.
*I am not convinced by interviews in general, but that's a whole thing I am admittedly not any kind of expert in.
**there's a story here but not one I will post publicly