system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5 - How can astronomers determine what a planet/moon is made of, just from a few pictures of it?
gpt
Spectroscopy.

Notice how different things are different colors?

This is because different chemicals absorb, emit, and reflect light differently.

Not only do we know how *nearly every* chemical absorption/emission spectrum (what light they absorb, emit, and reflect). We can predict it via quantum electrodynamics (Quantum Mechanics) for chemicals we haven't gotten around to inventing and testing yet. 

To go a step further this emission spectrum changes based on temperature the chemical is at. So knowing all of this a powerful computer (or a powerful computer in the 70's/80's... your smart phone is sufficient today) can decompose the spectrum and find a planet/star's temperature + chemical composition.