any time i try to sit down and learn a programming language it’s like my brain shuts off the key i’ve found is try to push through that initial foggy period because eventually you’ll strike upon some tidbit that is exciting to your brain and then all of a sudden you’re invested again   or if pushing through just isn’t working say out loud “i don’t want to do this because i just don’t care about this” then take a 5 min breakwhen i come back to the task sometimes i can magically focus xd