> It's unlikely the average C programmer has never written a program with undefined behavior
I'd add that the average C programmer can't spot UBs before they cause a problem, they are not your average bug. Unless you're very well read or are just told about them, that is.
> the average C programmer can't spot UBs before they cause a problem
No, the average C programmer probably can spot some UBs, but I think there are many more undefined behaviors than most C programmers realize. John Regehr wrote a series of blog posts about some of the trickier UBs, starting here: https://blog.regehr.org/archives/213
Looking at my own comment a day later and I think I had misread the parent comment as suggesting that "the average C programmer can spot UBs", which I felt the need to dispute.
I dunno how I made that mistake even after copy/pasting, but I did, so I apologize for that.