"Lamech said to his wives: 'Adah and Zillah, hear my voice; you wives of Lamech, listen to what I say: I have killed a man for wounding me, a young man for striking me. If Cain is avenged sevenfold, truly Lamech seventy-sevenfold'" (Genesis 4:23-24).
Cain was punished for killing Abel, but that punishment was not as severe as it could have been because Cain was ignorant of the severity of his action. Since it was the first murder, he had no precedent to know. Lamech was clearly aware of the story of Cain; nonetheless, he committed one or two murders depending on the translation. His guilt was magnified because he knew that what he was doing was wrong.