In Egyptian mythology, Apep or Apophis is a giant serpentine creature who resides in the Duat, the Egyptian Underworld.[24][25] The Bremner-Rhind papyrus, written around 310 BC, preserves an account of a much older Egyptian tradition that the setting of the sun is caused by Ra descending to the Duat to battle Apep.[24][25] In some accounts, Apep is as long as the height of eight men with a head made of flint.[25] Thunderstorms and earthquakes were thought to be caused by Apep's roar[26] and solar eclipses were thought to be the result of Apep attacking Ra during the daytime.[26] In some myths, Apep is slain by the god Set.[27] Nehebkau is another giant serpent who guards the Duat and aided Ra in his battle against Apep.[26] Nehebkau was so massive in some stories that the entire earth was believed to rest atop his coils.[26] Denwen is a giant serpent mentioned in the Pyramid Texts whose body was made of fire and who ignited a conflagration that nearly destroyed all the gods of the Egyptian pantheon.[28] He was ultimately defeated by the Pharaoh, a victory which affirmed the Pharaoh's divine right to rule.[29]