That said, I still managed to pull out a few nights of programming (the Synacor Challenge) and debugging, occasionally till 2AM while I barely get much sleep because we are trying to ditch the pacifier.
I have a feeling that humans can still burn extra mental energy when really driven, to certain limit. But in 40s we are driven by far fewer things than in 20s, and we need more rest for these burns. The up side is I know ourselves better now than in our 20s so I can at least achieve something. Back when I was in my 20s I spent most of the time playing games and failed to learn anything properly.