Answer:
You take the light from a star, planet or galaxy and pass it through a spectroscope, which is a bit like a prism letting you split the light into its component colours. "It lets you see the chemicals being absorbed or emitted by the light source. From this you can work out all sorts of things," says Watson