Understanding Software Bugs

Learn about software bugs and some real-world examples of them.

What is a bug?

When writing software, things won’t always go according to plan. The programs we create will contain bugs. The term bug is used to describe an error, flaw, or fault in a program, and it dates long before we had any computers. It has been recorded as a part of engineering jargon since the 1870s. In a letter to an associate dated 1878, Thomas Edison wrote the following:

“It has been just so in all of my inventions. The first step is an intuition, and comes with a burst, then difficulties arise—this thing gives out and [it is] then that “Bugs”—as such, little faults and difficulties are called—show themselves and months of intense watching, study, and labor are requisite before commercial success or failure is certainly reached.”

The first mechanical pinball game, Baffle Ball, was advertised as being free from bugs in 1931, and in 1944, Isaac Asimov used the term bug to describe issues with a robot in the short story “Catch That Rabbit.”

One story that has often been given tribute for being the origin of the term bug in software comes from Grace Hopper. In 1946, she joined the Harvard Faculty at the Computation Laboratory, where she continued her work on the Mark I and Mark II computers.

The Mark II computer produced errors and, after some searching, the operators found that the cause was a moth trapped in a relay. The moth was carefully removed and taped to the logbook. Under the moth, the following was written:

“First actual case of a bug being found.”

The date in the logbook was September 9, 1947, and that was the first time we had the term “bug” used in computer science:

Get hands-on with 1400+ tech skills courses.