Deuteronomy 22:24

Amplified Bible (AMP)
then you shall bring them both out to the gate of that city and stone them to death—the young woman because she did not cry out for help [though she was] in the city, and the man because he has violated his neighbor’s [promised] wife. So you shall remove the evil from among you.

Read Deuteronomy 22:24 in other translations