When sunlight  has continuosly varying wavelength in it. when sun light is dispersed through water droplet a bright spectrum of continously distributed colours is obtained that is rainbow. It is based on intensity of light at different places.Rainbow is continuous spectrum..

hope its help u..

2 4 2
This is also because of the refraction of light.
and at many places the colours are absorbed.
for eg. we see the sky blue because all other colours are absorbed and only  blue is reflected back.
1 2 1