Answer :

They actually pushed the British into Yorktown because they knew the British were beginning to lose. Then after the British were surrounded by land the French started firing at them from sea until they surrendered