Many (some claim most) Biblical scholars believe the five books of Moses were written in Babylon during the Jew’s captivity (cir. 600-400BCE). So, no doubt, most naturalists would agree with this point of view. The alternative would be that God pretty much dictated at least some of what Moses wrote; he also may have had some earlier records inherited from Adam, Noah and Abraham (or copies), and Moses contextually wrote about actual events witnessed by himself and others with him. Therefore, an argument of borrowing from her neighbors, viz. Babylonians and possibly Assyrians, who ruled over them in their captivity, is preferred, because naturalism cannot bear a contextual argument of revelation from God and a narrative of actual experiences.
With the above in mind, how should we understand the restrictions placed upon Israel’s military for warring activities, i.e. what they were and were not permitted to do when they besieged a city? Notice:
When thou shalt besiege a city a long time, in making war against it to take it, thou shalt not destroy the trees thereof by forcing an axe against them: for thou mayest eat of them, and thou shalt not cut them down (for the tree of the field is man’s life) to employ them in the siege: Only the trees which thou knowest that they be not trees for meat, thou shalt destroy and cut them down; and thou shalt build bulwarks against the city that maketh war with thee, until it be subdued. (Deuteronomy 20:19-20 KJV – emphasis mine)
If we understand this restriction as a revelation from God, then there is no reason not to receive the Noahic Flood narrative as contextually accurate, for why would we believe God revealed the above to Moses (or someone else) and not accept the argument that God caused a worldwide flood and warned Noah about it beforehand? On the other hand, if we choose to believe the siege restrictions of Deuteronomy 20:19-20 come from Israel’s neighbors, while they were in Babylon (the common understanding of at least many scholars), then from whom did Israel borrow the idea that fruit trees were not be used to build implements of warfare?
“…it appears from the current records available that it could not have been employed in reference to Babylonian, Canaanite, and Hittite tactics, and even less likely Assyrian practices. After a comprehensive survey of currently available iconographic, textual, and archaeological evidence, it can only be concluded that such a destruction of fruit trees points to an Egyptian background in the second millennium B.C.E.”
Under this polemic, Deuteronomy, the fifth book of the Bible and final book of the Torah was written before the Gilgamesh, the Atrahasis and the Eridu (Summerian) epics. In such a case, any argument of dependency or of copying would point to those accounts, while favoring the Biblical, Noahic version as a source for any one or of all of the others.
 Joseph Blenkinsopp, “The Pentateuch: An introduction to the first five books of the Bible” (1992), page 1, Anchor Bible Reference Library. New York: Doubleday.
 Michael G Hasel “Military Practice and Polemic: Israel’s Laws of Warfare in Near Eastern Perspective”; pp 127-8, AndrewsUP:2005.