Earlier quoted context omitted.
I'll second this. Based on my own experience (I'm 50) it's all about energy levels. When my energy is high, I can code like I did two decades ago. Probably better. I guess the difference is that in your twenties, energy is almost for free. As you get older, you've got to be smarter about it - all the usual things - diet, exercise, avoiding stress... Not that I'm good about those things - I do OK but not great. Someti…
I had unlimited energy till about 40 and then I hit some sort of cliff. This coincided with covid and being indoors using high velocity media like reddit/insta. I am not sure how much is age and how much is habits that caused this.
I recently did a big change in myself - adjusted sleep, took specific supplements which I was suspect was deficient in and have found my energy to be much fuller. Do not ignore what your body is telling you.