if you take a step back: do you… like what you’re studying or working on? i’m not saying that you have to love it, but if you’re having a hard time self-motivating on a particular subject, you might just not like it very much. i personally always figured programming was something i’d like and be good at given my specific spicy brain but turns out it wasn’t, so i pivoted into programming adjacent spaces (like the other poster mentioned) instead. i think i dropped out of like two different boot camps before i figured that… well, i just didn’t like it, it it didn’t motivate me, and it wasn’t for me.
often, these programming-adjacent spaces (eg: cybersecurity, system administration, integration management, salesforce admin) have problem solving with more fixed parameters than programming - like looking at a word problem instead of a blank page - and could work better for you.
as an omnivore dating a vegetarian who doesn’t eat meat for ethical reasons i am so, so excited!!!