How does science know the age of the earth?
When the Earth formed, there are elements which got together by affinity (chemistry). Others that did not. For example, there was little reason for Uranium to mix with lead (there may have been some accidental mixing, but it would be purely random). Yet, every time Uranium was found, there was some precise lead isotope mixed in with it. Furthermore, it was not even a natural mix of lead isotopes. When lead is found by itself, in nature, it contains a particular mix of three stable isotopes (atoms with different numbers of neutrons). When lead is found mixed in with other compounds, it has the same mix of the same three isotopes. When lead is found in compounds (chemically combined with other elements), it has the same mix of the same three isotopes. When lead is found mixed with Uranium, it is almost all of the same isotope. The reason is that the lead found with the Uranium was formed from the decay of the Uranium atoms (this can be checked in a lab). We can measure how long it takes