Lurker News
I'm around 40 and recently I have been asked to port an API from one language to another. The code I'm porting is average code, not terrible, but plenty of little things to complain about.

I feel like my past self could have handled this task, but I am really struggling. Porting this API will require a deep understanding of the existing API, which, of course, has several layers of abstraction.
I can't seem to hold more than about 2 levels of call stack in my head. There's the entry point function which calls other functions, which call other functions, which call other functions, etc. You know how it is, code calls other code, and logically it forms a tree of calls and return values that often goes several layers deep. I struggle to hold more than about 2 levels of this call stack in my head. 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.
I don't know how to break this into small enough chunks that I can understand it or make progress on. Imagine I gave you the code for the sha512 algorithm, and a hash, and asked you to find the pre-image (the input). This is how I feel. Where do I even get started? How do I find even a single chunk of manageable work to break off.
The hard part is, several other developers are making progress on porting this API. Why can't I? What happened?
I don't know if this task is just an especially bad fit for me, or if my mental abilities are declining?

Comments (510) 299 threads

Earlier comments
wusher1 reply#
Not sure if OP is a male or not but if you are get your testosterone levels checked and if they are low, fix them. I was going through the same thing at the same age. Your milage my vary but that was a complete game changer for all aspects of my life.
anon7725#
I would also suggest getting tested for vitamin B12 levels. I began taking B12 injections to compensate for a very low level and it has been a night and day improvement in my energy levels and ability to focus.
pmarreck#
I recently turned 50 and am finding the same (to the point that I might want to step "down" to something a little less intellectually-intense like sysadmin) but in my case it's the fact that 18 month old toddler sons are pretty much life-absorbers.

Yesterday I realized that a hard-ish problem in my tiny shell script testing library https://github.com/pmarreck/tinytestlib which I had worked on for over a day was completely moot, and ripped it out while facepalming.
Incidentally, I'm looking for work as... well, the above things, although previously I was a solo Elixir dev.

graderjs#
Sounds hard, man! Poor you :( General tips: exercise, lots of water, meditation/pranayama, emotional processing/therapy if you have unresolved trauma, sleep, cut coffee and alcohol, cut processed foods/snakcs, more vegetables. Maybe try some nootropics? Nootropics are a highly-opinionated / personal / subjective topic but there's plenty of different options. Worth exploring as temporary rewiring enhancement while you get your personal health routine up to sustain your abilities. Also if you can and want to maybe take a break / sabbatical from work and just see where it takes you. What do you want to do?
habibur#
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.

Load more comments