Here is a tip kids. Go to the dentist before your teeth start hurting. Don’t do what I did, and wait till the last minute. Otherwise you are in for a fun ride.
I think the hole in my tooth somehow developed some extra mutated nerve endings. My tongue was essentially all numb, and the whole side of my face had no feeling but I could feel every freakin thing that the dentist was doing to my tooth. My whole jaw still hurts – I don’t know if it’s from the shots, or from the muscle tension or both. I may or may not have to have a root canal. It depends if it continues to bother me or not…
This whole thing got me thinking… Dental care is kinda like software engineering. Going to the dentist in some ways like refactoring. No, I’m serious. Badly designed code is essentially akin to tooth decay. You can ignore it for a while, because fixing it might be scary and it can potentially mess things up. But at some point it becomes such a pain, that you will be forced to do something about it. And the longer you wait, the worse it gets.
If you resolve it early in the development process – say the instant you realize that your design is flawed, the whole procedure might be relatively painless. You can use the built in tools in your IDE, rebuild and be done with it. You may need to spend some extra time testing it, or making sure that everything works properly.
If you wait till the last minute though you might be in for a real pain. Bad design will often force you to make more bad design choices, to overcome the inherent shortcomings, and quirks of your code. A wrapper class here, some glue code there, few ugly hacks to patch things together – these things accumulate and create layers of kludgey code which is neither easy to debug, nor easy to refactor. No IDE can automatically clean up your code, if what you wrote is a tangled web of workarounds, and dirty hacks built around a broken model.
[tags]dentist, tooth, teeth, dental care, programming, refactoring[/tags]