This is a normal mode of self-conscious thought for a huge number of people who are otherwise excellent at their jobs and perfectly functional (e.g. introverts).
Plus, after you've worked a job for a while and know your team, know what's expected of you, and can get in the zone with some privacy, then these thoughts no longer really affect you. So they only play a significant role during an interview specifically because the interview is not at all a realistic representation of what working will be like.
I find it incredibly disturbing that you see fit to infer anything from the author's so-called "inability" to program "under stress." When someone makes that kind of inference, I think it says a lot more about their dysfunction as a colleague than it says about the other person's programming skill. Even if this problem had been Fizz Buzz or swapping two numbers, it's so, so far from simulating what a real work social situation would be like that it renders it useless for assessing the candidate, no matter if they answer it perfectly or fail completely. It's just a useless scenario.
I spend maybe four hours per coding in a moderately complex domain where I have zero need to know how to write a bfs. To ask someone to do it, then to ding them on it is just self-masturbatory behavior.
Something like that, right?
I sort-of agree that these specific tasks shouldn't be used as an indicator of programming skills, but a breadth-first-search is really quite simple. It's mode of operation is in the name, and even if you haven't implemented one in a while, you should be able to derive some valid pseudo-code after a while. Especially if you do as much coding as this person claims, and thus are confronted with problems to solve on a regular basis.