Imperative Programming
Undergraduate course, Pontifical Catholic University of Paraná, 2025
In this course, we discussed what the imperative programming paradigm is and how to write code following its principles. Rust was the programming language used throughout the course. By the end of the semester, students were expected to develop a simple terminal-based application that applies all the concepts covered.
Technologies used:
rust v1.88.0
cargo v1.88.0
git v2.50.0
- Visual Studio Code
Topics discussed:
- What is the imperative paradigm and related languages
- Variables
- Primitive and complex types
mut
variables
- Control flow and loops
if
,else
,else if
- Pattern matching
while
,loop
,for
- Functions
- Recursion
- References (borrowing)
- Raw pointers
- Structs
- Enumerations
- Implementations
- Rust’s memory management
- Binaries memory structure
- Ownership
- Borrowing
- Error handling
Result
Option
- Data collections
- Static arrays
Vec
Iterator
- Code modularization
crates
modules
- Scope control and “privacy” (
pub
)
- Version control (
git
)
Slides: