It's a largely undiagnosed problem because most people just "adapt" and it's not until you get to be in your 40's or 50's that your heart starts to show signs of problems. IF you have sleep apnea, you are missing out on a lot of REM sleep, where your repair hormones are released and also, long-term memory assimilation occurs.
The first night I used my machine correctly, I woke up 4 hours before my normal wakeup time, thinking I overslept. I went back to bed again and woke up normally and for the first time in year, realized my EYES didn't hurt. Went and did like 16 hours of straight work after that.
Long-term effects? I'm pretty sure my functioning IQ went up 10 points thought that's obviously a subjective sample size of 1. Bottom-line though, I just seem to figure things out quicker and have a lot more energy.
I hope this is your problem because it's a real easy fix. Just go to bed.
https://www.youtube.com/user/TheLankyLefty27 that's his Youtube Channel
Have enough patience/motivation to experiment until it works. You'll know when it does. You might need a different mask, a refit, switch from nose to full-face, something.
My problem was I'm slightly claustrobic - and wearing the full mask reminded me of my mask I wear at the Fire Department. There I can always mentally power through it and focus - but with the CPAP, you literally can't focus while you are TRYING TO FALL ASLEEP. I ripped the damn thing off my first night.
I watched that Youtuber's videos and found one of the tips about relaxing and used it on the 2nd night and have never looked back. I'm talking "from my cold dead hands" will you take my cpap away.
Seriously, when you write down stuff you read/hear you're making your brain process the same information several times (reading/hearing, understanding, rephrasing, converting that info to letters, hand movement to write that letters, understandig).
This helps retention a lot, plus you'll have notes that you can refer later.
Don't use a computer to keep notes: keyboard punching needs far less neurons than handwriting and retention is less effective.
I think there is some research about that, btw.
You need to revisit new information because we forget things exponentially unless we remind ourselves. In psychology, such pattern is shown by the forgetting curve [0].
Similar to you, I was concerned once that I was forgetting a lot of new information about programming. Therefore I wrote an open source software to automate spaced repetition with minimal friction while coding [1]. Basically, you write down new information as you come across it, and you get a weekly digest email.
Everyday, try to write information down on a piece of paper or on your machine. The act of writing down the information in your own words alone could help you retain memory. The retention could be all the more improved when you continually revisit what you have written down. This habit has worked well in my case for the last 2-3 years. Hope it could work for you too.
Make heavy use of todo lists, probably plaintext. Often when you're programming something, a lot of tiny issues crop up that wreak havoc with your short term memory. It's sort of like doing calculus, you just have to learn to write more steps, instead of trying to skip a few steps ahead.
Keep as few tabs open at a time as possible. Ideally, around 4 or so.
One function should do only one thing. Memorize the shortcut for jumping to a function by name. If it's too hard to understand what a function is doing, split it into more.
Also, revisit already learned stuff again 3 to 4 days later. Multiple spaced repetition makes the concepts stick.
Also, don’t be pressured by others’ performance. It’s your pace and your schedules. Don’t believe those book covers either ... you cannot learn programming in “24 hours” or even “21 days”.
Shit is hard for everyone. Oh ya, did I mention getting enough sleep? Min 8 hours a day.
and as others said, get good sleep.