Most of my career would be about 10% but in the past few years its shot up. This is mostly because I'm doing simpler projects, and I have become better at testing/debugging on the fly (as I'm sure we all work in a modular way). And of course, using MCU's, if one has built up their own software libraries that have the bugs ironed out over time leads to less traps.
But I agree with some of the comments - depends on what you mean by "work". If you have a vague goal, such as "light this LED if I get a signal from something" then chances are it's going to be easier to achieve than "get 32 wireless devices on a mesh network in the field".
Aside from quite simple projects, does anyone just knock something up without simulations or tests and power it up without checking anything first? I would have thought most of us would have done that perhaps when we were starting out, but quickly learned that breaking the problem down into smaller parts, that each can be tested is a more reliable and quicker way to achieve a goal. This greatly increases the chances of things going well first "power on".