1.3. Our choices for this course

Programming and software development are very large areas. There are lots of different programming languages, and software development environments that we could chose to study! Here we include some motivations for the choices that we’ve made in terms of languages. When we go over software tools we’ll give the motivations for the different tools we’re going to work with.

1.3.1. Python

The course aims to give an introduction to both general purpose programming, and a lower level systems programming language.

For general purpose programming, Python is the obvious choice. It is very widely used, and commonly listed as the most widely used programming language. It is used extensively for machine learning and for data science, as well as more general task automation. Many students will also be starting the course with some previous experience with Python from their school level studies.

1.3.2. C/C++/Rust

For a lower level language, there is more debate as to the most suitable choice. C, C++, Java and similar are all widely used. Historically, we taught C. Before this we taught Java, and before that it was C.

There are billions of lines of C and C++ code that have been developed. These will continue to be used and developed for many years to come. We will spend most of our time on C, with an introduction given to C++ as this is what you will use next year in your Microcontroller Engineering course.

We also spend some time on a newer language called Rust. This is due to memory safety. We will cover this more later in the course, but briefly, memory safety refers to ensuring that the program can only see areas of memory that are associated with that particular program. It’s relatively easy to accidentally write C programs that can access other memory locations and which can be exploited by malicious actors to run code or access data that they shouldn’t have access to.

The National Cyber Security Centre, and international counterparts, have called for code to have a roadmap towards being memory safe. Indeed they state “Organizations should signal their demand for developers trained in security and memory safety to colleges, universities, and educational institutions.Google estimate that in 2024 24% of security vulnerabilities in Android were due to memory safety issues. (Down from 76% in 2019 due to their increased such of techniques such as switching to Rust.)

Rust as a programming language has been designed to help minimize memory safety issues. We’ll thus spend some time looking in to this.

1.3.3. Shell scripting

While the above languages represent the main focus of the course, some topics are needed around these in order to give you a solid grounding in programming.

We will meet the terminal or command line interface shortly. We use the command line extensively when programming, and shell scripting is the process of automating tasks for the command line. We’ll use the command line quite a lot during the course, and so we’ll spend some time at the start developing some familiarity with it.