Deuteronomy 17:2-7 NASB1995
“If there is found in your midst, in any of your towns, which the LORD your God is giving you, a man or a woman who does what is evil in the sight of the LORD your God, by transgressing His covenant, and has gone and served other gods and worshiped them, or the sun or the moon or any of the heavenly host, which I have not commanded, and if it is told you and you have heard of it, then you shall inquire thoroughly. Behold, if it is true and the thing certain that this detestable thing has been done in Israel, then you shall bring out that man or that woman who has done this evil deed to your gates, that is, the man or the woman, and you shall stone them to death. On the evidence of two witnesses or three witnesses, he who is to die shall be put to death; he shall not be put to death on the evidence of one witness. The hand of the witnesses shall be first against him to put him to death, and afterward the hand of all the people. So you shall purge the evil from your midst.
NASB1995: New American Standard Bible - NASB 1995