<P> For much of the 20th century most scholars agreed that the five books of the Pentateuch--Genesis, Exodus, Leviticus, Numbers and Deuteronomy--came from four sources, the Yahwist, the Elohist, the Deuteronomist and the Priestly source, each telling the same basic story, and joined together by various editors . Since the 1970s there has been a revolution in scholarship: the Elohist source is now widely regarded as no more than a variation on the Yahwist, while the Priestly source is increasingly seen not as a document but as a body of revisions and expansions to the Yahwist (or "non-Priestly") material . (The Deuteronomistic source does not appear in Genesis). </P> <P> Examples of repeated and duplicate stories are used to identify the separate sources . In Genesis these include three different accounts of a Patriarch claiming that his wife was his sister, the two creation stories, and the two versions of Abraham sending Hagar and Ishmael into the desert . </P> <P> This leaves the question of when these works were created . Scholars in the first half of the 20th century came to the conclusion that the Yahwist was produced in the monarchic period, specifically at the court of Solomon, 10th century BC, and the Priestly work in the middle of the 5th century BC (the author was even identified as Ezra), but more recent thinking is that the Yahwist was written either just before or during the Babylonian exile of the 6th century BC, and the Priestly final edition was made late in the Exilic period or soon after . </P> <P> As for why the book was created, a theory which has gained considerable interest, although still controversial is "Persian imperial authorisation". This proposes that the Persians of the Achaemenid Empire, after their conquest of Babylon in 539 BC, agreed to grant Jerusalem a large measure of local autonomy within the empire, but required the local authorities to produce a single law code accepted by the entire community . The two powerful groups making up the community--the priestly families who controlled the Temple and who traced their origin to Moses and the wilderness wanderings, and the major landowning families who made up the "elders" and who traced their own origins to Abraham, who had "given" them the land--were in conflict over many issues, and each had its own "history of origins", but the Persian promise of greatly increased local autonomy for all provided a powerful incentive to cooperate in producing a single text . </P>

When was the book of genesis in the bible written
find me the text answering this question