And God said, Let there be light: and there was light. (ASV)
The light is created on the 1st day in Genesis 1:3-5. Yet, the CAUSE of the light is created on the 4th day, according to:
"And God said, "Let there be lights in the expanse of the sky to separate the day from the night, and let them serve as signs to mark seasons and days and years, and let them be lights in the expanse of the sky to give light on the earth." And it was so. God made two great lights - the greater light to govern the day and the lesser light to govern the night. He also made the stars. God set them in the expanse of the sky to give light on the earth, to govern the day and the night, and to separate light from darkness. And God saw that it was good. And there was evening, and there was morning - the fourth day."
According to the 1st chapter of Genesis, the light (the phenomenon of day and night) was created after the cause of light. How can the cause of light be created after the light itself? It is like saying: a watch was created, before the creator of the watch existed.
The source of the light in Genesis 1:3 is never stated, so it's only a supposition that the writer claimed it had come from the sun which was created three days later.
Edit this section to note miscellaneous facts.