Learning Programming Languages
When learning computer languages, order matters a lot, and I think I got lucky by learning them in roughly the best possible order.
Just like a linguistic ladder , it’s better to take many small steps than a couple of big steps.
Bash is a great first language because you can start instantly, and do regular things easily.
Consider the following python commands to see which files are in a directory:
import os os.listdirs
Whereas in bash, we have:
The Python equivalent of
grep sounds positively terrifying.
And for python, downloading some new library involves
pip3 on some systems), then you’ll need to decide if you’re installing that locally, system-wide, or using a virtual environment.
Alternatively, some of those python packages could be in the system’s package manager, but then you need to ensure you don’t get those packages mixed up with a system-wide installation from pip.
Once installed, the package must be imported every time it’s called, and when using multiple files, the package must be called in the correct place.
With bash, it’s just ‘
apt install fd’, and you’re good to go.
These little programs can let you know when a big download’s complete, find where you stuck some old project, or search for and download torrents.
Of course, once a bash script grows over a hundred lines, and starts to need some structured data, python becomes the easier tool, and you can breathe a sigh of relief that you no longer have to tell bash that a number is not a string every time you want to work with it.
I did a couple of afternoons of C++ shortly after the python. I don’t have any use for it, but learning the basics about memory management gave me a better idea of how python (or any computer process) works.
While one could just create a
nodejs program, the standard use of web-pages mean you’ll come across three languages within the documentation, as so many examples include HTML and CSS specifications.