Grace Hopper and the Moth
When software doesn't work properly, we say that it's buggy. The term de-bug is used to describe the troubleshooting process used to correct software problems. Even some software updates and patches are called bug fixes. The association with bugs and electronics/computers has been around for decades, and its origins are rather fascinating. Thomas Edison used the term over a century ago when discussing problems in electrical circuits.
The first documented case of a real bug inside a computer took place in the 1940s when researchers at Harvard University discovered a moth inside a computer system there. To understand why a moth would cause so much trouble, you have to know how computers were originally designed.
The first computers were nothing like what we have today. Back in the early days of computing, they were built using a series of vacuum tubes and relays, and the computer could be the size of a house. These giant contraptions were made up of devices that looked like something out of a bad sci-fi movie, but those building blocks lead to the powerful desktop or laptop you have at home now. An incredible amount of work was needed just to do simple mathematics problems on the first computerized adding machines, but you have to understand that the idea of a machine doing computations was truly revolutionary for the time.
In addition to all the components we might consider archaic now, those giant computers also used a lot of light bulbs, and this attracted bugs--especially moths. As such, they were extremely sensitive to outside interference, and their size made the likelihood of problems even worse. It was Grace Hopper, a pioneer in computing and programming as well as a Rear Admiral in the U.S. Navy, who discovered the bug and documented the incident. The image shown here is from her actual log book, and she taped down the bug that was discovered between the relays in the system.
What's funny about this story is that the term 'bug' was around long before this real bug was discovered. This famous incident can now be found in countless textbooks and shows how some phrases can stick. Before those Harvard engineers could get their computer working again, they had to get the bugs out--literally.