Programming fundamentals
Values and types, memory, control flow, functions, recursion, lists and strings, errors and tests: the first programming course of any CS degree.
Course · 8 lessons · 57 min
Taught inComputer ScienceData ScienceArtificial IntelligenceCybersecurityTelecommunications
- 1Values and typesFreeEvery value has a type that fixes what it can hold and what you can do with it. Integers, floats, booleans and strings, and why 0.1 + 0.2 is not 0.3.1985–today · 7 min
- 2Variables and memoryA C variable is a named box in memory; a Python variable is a name bound to an object. The difference explains pointers, aliasing and leaks.1972–today · 8 min
- 3Control flowSequence, selection and iteration are enough to write any program. How if, while and for work, and how to count what a loop does.1966–1968 · 7 min
- 4Functions and scopeFunctions turn a program into named, testable pieces. Parameters, return values, and the rules that decide where each name is visible.1960–today · 7 min
- 5RecursionA recursive function solves a problem by solving a smaller copy of it. Base cases, the call stack, and when recursion is the right tool.1960 · 7 min
- 6Arrays, lists and stringsArrays give constant-time access by position; strings are sequences of characters stored as bytes. Indexing, slicing, costs and encodings.1950s–1992 · 7 min
- 7Errors and debuggingSyntax errors, exceptions and logic errors fail in different ways. How to read a traceback, handle exceptions and hunt a bug with a method.1947–today · 7 min
- 8Testing basicsA test runs code on a chosen input and checks the result. Unit and integration tests, equivalence classes, boundary values and coverage.1970–today · 7 min