This is a colloquial expression, meaning that someone has suddenly understood something. It is probably derived from the old public telephone machines in Britain, where you put in your money [a penny or two] in the slot to make a call, but the money did not drop into the collecting box until the connection was actually made. So, I might use the phrase as follows, "I could not understand why Marilyn preferred Jim to me. Then I saw him pick her up in his Rolls-Royce, and the penny dropped".