Game Genie

A Game Genie is a cheating device that patches the ROM of a game to allow for various benefits, challenges, or unused items. It was released for several systems, including the NES, Game Boy, SNES, Genesis/Mega Drive, and Game Gear. It sold over 5 million units worldwide, and paved the way for later cheating devices such as the CodeBreaker and GameShark.

Each Game Genie came with a book filled with codes for then-current games, and people could subscribe to a mailing list for updated codes. Thanks to the internet, you can find codes through a simple search or dedicated sites like GameGenie.com.

Later versions of Game Genie for the Nintendo systems included the ability to let the device's changes be undetected by checksums Nintendo had added to later games for this specific purpose (introduced during its lawsuit against Galoob, which the Big N lost). Sega, on the other hand, heartily endorsed it.

Code Format
An overview on the code format for the NES version can be found at romhacking.net.

Download
According to Zophar, the NES version is in the public domain. Emulation has allowed Game Genie (usually combined with Pro Action Replay) to be "connected" to the system at all times, making the ROMs little more than historical artifacts.

Still, if you want to see what the NES version looked like, here's the ROM.