Live data from Hacker News

Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

news.ycombinator.com

31–40 of 534 posts

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#31
> I can't seem to hold more than about 2 levels of call stack in my head.

If you keep thinking that you can't then you won't.

I recommend you to stop worrying and do the work. In time you will find ways to accomplish your tasks. In any case you can't go buy a new brain so why spend time worrying?

Looking at it differently: Even if a young you had greater mental ability, did young you have the same skills, experience, knowledge etc.?

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#33
post #3

Is the current API under test? Your number #1 priority with any port or major refactor is getting the current implementation defined and under test, so any replacement can be tested against the same tests. Once you've done that you should have a solid foundation and understanding of what the API actually does . In getting it under test, you'll also build up better mental models of which parts are actually separate an…

Adding to this:

> By the time I'm down in the weeds I've forgotten what I'm doing, what the purpose of the actual API call is.

If I can craft tests up front in terms of the higher level goals then when I finish a subcomponent or get distracted by something else the higher level test is there for me to fall back on to figure out what to do next.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#35
I am about 15 years older than you and I understand the worry. Things do take a little but longer to sink in and a little bit longer to hold in your head (I need to be a little more intentional about remembering and I love having a notebook or random piece of paper nearby to scribble in).

But I think the biggest difference comes when I care about something or not. The other day I was reading through the material for the Full ham radio license in the UK because it's about bloody time I got the Full one rather than the lower level. And because I was interested I easily recalled the next day that the impedance of coax used by hams is typically 50 ohm, television feeds typically uses 75 ohm and ladder line is 450 ohm.

If you're doing something that doesn't interest you don't be surprised that your brain isn't interested either! Also, if you have a life then tiredness, worries, stress, etc. all kill your coding vibe.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#36
Any number of things can affect your ability to handle abstraction. (Including just not being interested.) Other people in this thread will probably bring up all kinds of ideas for external forces affecting your mental capacity.

First thing you should do is figure out what's wrong. Refer to what other people here are saying. Additionally, see if your family history includes a history mental illness or degenerative medical conditions (including dementia and Alzheimers). Everyone knows someone with this, you're looking for a pattern. For example, multiple people in my maternal grandfather's family had been institutionalized and most of the family had bipolar and schizophrenia diagnoses.

And now, how to still get your job done... :)

At one point in my career, my mental facilities became so compromised, I couldn't follow abstraction. Instead of seeking help, I figured out a system to overcome this.

What I did was externalize my memory. Quite literally, I would write everything I needed to paper: variable names, notes on their contents, call stacks.

Once the entire set of function calls where on paper, I could see the structure and continually shuffle things in and out of very limited working memory as I worked to understand and fix issues.

It's slow, but not as slow as you would think.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#37
post #28
post #17

I don't know you personally but I doubt cognitive decline has anything to do with this. As we age, we usually end up with more and more life responsibilities, beyond just the work we are doing. All of that is input to the brain and requires energy in response. The brain is not infinite. I often feel as you do, but then I have periods where I am as light and agile in my productivity as 20 years ago, maybe even more so…

Also, our standards improve as we age. I wrote a lot of high-energy seemingly clever code when I was younger, but it was nonsense and terrible to read. Now I would not allow myself such indulgence, and so I work differently, maybe at times more slowly, and it might seem this is due to less abilities, but actually it is due to wiser experience.

It turns out the same dynamic is at play with songwriting - your standards get higher, what seemed novel when you were 20 now seems boring. I’m sure it is the same across disciplines. The irony is, it kills creativity.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#38
I'm in my early 30s, have been programming for 10+ years and have this from time to time but as another comment said I don't think it's age related but more burnout or general tedium of the task. As I get older I do notice I have to force my brain a bit more to do boring tasks like the one you're describing, it feels like I'm not necessarily mentally declining but have less patience for these kinds of tasks and have a better idea of what I'd rather be spending my time on (creative tasks, friends, family).

Also anecdata but I'm finishing up a project in which the CTO of the company has a good 15 years on you and seems as sharp as ever.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#39
I felt the same when was infected from Covid. That remained for 6 months, and then gradually went away.

At the downtime I felt like +20 or 30 years older and gone retarded. Can't do any more hard brain work, and felt like I can't do that ever.

But this will pass.

Re: Ask HN: I'm 40 and feel my mental ability declining. Programming seems harder.

#40

40 has nothing to do with it. Every other day I see a Ask HN post from younger people bringing up depression, burnout, and apathy. Listen, there are 60 year olds that look like our long held image of a 60 year that can barely walk or do anything. And then there are 60 year olds that go to the gym everyday. How do you want to play this? I don’t accept your premise that 40 has anything to do with it. Being a miserable…

There's a lot of biology in the mix here to that must not be dismissed.

But I like your take. Do everything reasonable to continue forward and maintain your body and mind.

Just don't completly ignore your genetics and biology and be open that they might speak-up and have a say too.

Post reply on HN