Download PDF

Coding Languages

In this class, you’ll learn Python, with a few glimpses at some other languages just for the sake of comparison.

We do this because Python has two features that make it ideal as the first (or only) language that you learn. First, it’s widespread as an instructional language in undergrad CS courses because it’s kind of a happy medium of all the different programming languages out there. It’s amenable to a wide variety of styles of programming–what you’ll learn to call imperative, object oriented, or functional paradigms. Second, it’s the lingua franca of a particular sort of research computing particularly around artificial intelligence and the humanities themselves.

But what you learn in python transfers easily elsewhere. Don’t be confused by the name–computer languages aren’t really languages at all, and one is not nearly as difference from another as Spanish is from French.

For the record, you should know about the following other languages:

  1. Javascript. This is the language the Web runs on, both in your browser and, increasingly, on the servers behind them. It’s the only other general- purpose language I would think of using in an intro to programming course; we don’t because while Python is well designed and consistent, Javascript has rightfully earned the reputation of being, let’s say, kind of a mess. That said, if you want to write for the Web, you’ll have to do it in Javascript. And I personally find the new flavors of the language more fun to write in than Python, although this is an extreme minority opinion.
  2. R. The second- or third-most widely used language in the humanities (after Python and maybe Javascript) can do everything Python can, but is especially designed for working with data. That’s why we use in the “Working with Data” class here in DHSS. Especially with the so-called tidyverse tools, it offers a clearer path to describing and modeling data directly than Python; but it is often more opaque when you want to do something like, say, shuffle the letters in a string.
  3. C and C++; these are older languages that allow code to get closer to the performance limits of your machine because they require you to be more explicit about what you want than does Python. (Specifically, they make you )