I know it has been answered already, but I would love to add my bit:
"The moon is losing mass. It is slowly moving away from Earth at the current rate of approximately 2 inches per day".
No, it is not losing mass, it's actually gaining mass from meteor and asteroid strikes, but very little. No again, it is not moving away from the Earth approximately 2 inches per day. It IS moving away, but the actualy distance is about an inch and a half (38mm) per year.
"If this is true, then the moon used to be much closer".
Yes, the moon WAS much closer. In fact, one present theory is that the moon was actually part of the Earth, knocked loose during an impact with a celestial body. In this sense, it wasn't just close, it was part of us.
"The inverse square law says if you half the distance you quadruple the attraction."
Correct.
"So 30-40 million years ago the tides would have drowned everything on Earth twice a day".
Oh dear, just when you were getting close. Firstly, the moon's formation was a long time ago, probably when the Earth was still in a molten state (and if it was formed by impact, it would probably have re-heated the Earth to some degree). There was no liquid water at that stage, and certainly no life. Even if, at a later stage, it did cover the land twice a day, since life began in the sea, this would be a positive thing, not the negative thing you imagine.
"That’s only 30-40 million years! Imagine 2 billion!"
I'm imagining it. Even if the rate of movement was steady (and this is unclear, it may be accelerating). 38mm per year means it moves 1 mile every 42,240 years. or,,, 1000 miles every 42,240,000,,, or 20,000 miles every billion years (give or take a few). Since the moon is 238,857 miles away now,,, a billion years ago, it might have been 219,000 miles away. Not such a big difference, is it?
"Please explain how the Earth can still be billions of years old? "
Well, it's very easy, really. Do you mean the planet itself, or life on Earth? The planet itself is probably around 4.5 billion years old, according to radiometric dating of meteorite samples, whereas it would appear that the first eukaryotic cells (those with a nucleus) developed, with complex systems of organelles and membranes, between 1 and 2 billion years ago.
So,,, what was your point again?