A rainbow can seem like magic, but it has a clear scientific cause. You usually see a rainbow when the sun is shining and raindrops are still in the air. The sun must be behind you, and the rain must be in front of you.
Sunlight looks white, but it is really made of many colors mixed together. When sunlight enters a raindrop, the light bends. This bending is called refraction. Then the light reflects off the inside of the raindrop and bends again as it comes out.
Because each color bends a little differently, the white light spreads apart. Red, orange, yellow, green, blue, indigo, and violet become visible in an arc across the sky. Red usually appears on the outside of the rainbow, and violet is on the inside.
You cannot walk to the end of a rainbow. The rainbow changes as you move because it depends on the angle between the sun, the raindrops, and your eyes. That is why two people standing in different places may not see exactly the same rainbow.
What is this passage mostly about?