David was well skilled with a sling shot...and this is what he used to knock out Goliath..before using Goliath's own sword to cut off his head.....
But the Boldness and audacity of Faith he demonstrated from the time he witnessed Goliath's challenge could only come from time spent with God and knowledge of the Covenant....
Hear the words of Young David:
1 Samuel 17:26 NKJV
Then David spoke to the men who stood by him, saying, "What shall be done for the man who kills this Philistine and takes away the reproach from Israel? For who is this uncircumcised Philistine, that he should defy the armies of the living God?"
1 Samuel 17:45-47 NKJV
Then David said to the Philistine, "You come to me with a sword, with a spear, and with a javelin. But I come to you in the name of the LORD of hosts, the God of the armies of Israel, whom you have defied.