While this post at Depth First is about learning to code as a chemist, it's generally applicable to anyone. Some great quotes too.
Identifying good problems - problems that when solved will yield profitable outcomes - is one of the most difficult and valuable things we do in our careers as scientists. This is equally true in software.
Finally, you can only learn so much from a lecture or book. You must practice getting yourself into trouble and back out - repeatedly.
The pattern is pretty clear: I never learn a programming language unless it’s the best way to solve a particular problem.
I'll add Python as a good language for any scientist to consider. It's grown organically up around the sciences and has some extremely specific library modules aimed at chemistry problem solving.