First immerse yourself in it.
Subscribe to YouTube channels, follow tik toks, follow X pages, whatever you need to do to get programming things in your face as much as possible.
Then go through the basic tutorials on sites such as codecademy or team treehouse.
Once you have a basic understanding, then do this next thing.
When I got my certification in copywriting, the instructor told us to find successful copywriting, and just spend a hour copying it word for word.
Do the same thing with programming.
Find the source code of a type of program you would like to work on, then copy it line by line, source file by source file, and really think about the code while you’re typing.
If you catch yourself zoning out, go back to the part where you started zoning out and go back to copying.
Tutorial sites such as codecademy.com are great for learning the basics and syntax of code and copying real-world programs will teach you how to structure code.