Exodus 17
9 Ref Moses said to Joshua, "Choose men for us, and go out, fight with Amalek. Tomorrow I will stand on the top of the hill with God's rod in my hand."
10 Ref So Joshua did as Moses had told him, and fought with Amalek; and Moses, Aaron, and Hur went up to the top of the hill.
11 Ref It happened, when Moses held up his hand, that Israel prevailed; and when he let down his hand, Amalek prevailed.