I’m sure we have all done this at some point. Whether it was your computer running especially slow or your television just wasn’t giving you that “clear” picture. It just seemed liked a quick smack was the right thing to do to fix that problem! It worked for Fonzie to fix that skipping jukebox from “Happy Days”, so why can’t it work for you? Well in the older days when devices had many more mechanical components in them, and something could get jammed, a quick hit could get it right into place or a bad solder connection would reconnect. However, these techniques would only be a temporary fix, prolonging the inevitable.
How about more modern machines where many of the components rely less on mechanical operations? Well placing a few well-placed taps could identify a weak connection on a printed circuit board giving you an indication of a weak point in the part. There are definitely items where giving them a good smack would not help but do more damage than help. For example, giving a hard drive a good whack may not be the best solution. However, this so called “percussive maintenance” is still used today to determine faults in electronics like weak solder connections. This percussive maintenance is done by professionals where knowledge and experience comes into play. They know how to perform a few well-placed taps rather than throwing a Mike Tyson punch to the side of the device.
You could compare the “smacking back to life” idea to a doctor applying a “precordial thump” to the chest of a person in cardiac arrest. However, I would not suggest you do this unless you are a certified emergency aid.