The sun burns at a constant rate. If the earth were truly millions of years old, the sun would have been large enough to touch the earth. The equation of something traveling a given distance divided by the speed it is traveling:
Time=Distance/Speed
When you apply this to stars, it turns out to...