Do Not Murder and Do Not Commit Adultery as Warnings

Yalkut Shimoni on Torah 298:4

(Exodus 20:13-14) "You shall not murder" — why is it stated? Because it says "One who sheds the blood of man" and so forth (Genesis 9:6): we have heard the punishment, but we have not heard the prohibition. Scripture teaches, saying "You shall not murder." "You shall not commit adultery" — why is it stated? Because it says "The adulterer and the adulteress shall surely be put to death" (Leviticus 20:10): we have heard the punishment, but we have not heard the prohibition. Scripture teaches, saying "You shall not commit adultery."

Themes