Skip to content

Latest commit

 

History

History
30 lines (22 loc) · 1009 Bytes

README.md

File metadata and controls

30 lines (22 loc) · 1009 Bytes

C++ Modules 00–06

My solutions to the C++ modules of the 42 Common Core: a step-by-step introduction to object-oriented programming in C++98.

Module Topics
00 Namespaces, classes, member functions, iostream
01 Memory allocation, pointers vs references, switch
02 Ad-hoc polymorphism, operator overloading, Orthodox Canonical Form, fixed-point numbers
03 Inheritance
04 Subtype polymorphism, abstract classes, interfaces
05 Exceptions (try / catch, custom exception classes)
06 C++ casts: static_cast, reinterpret_cast, dynamic_cast
Exam04 Mid-curriculum exam exercise

Build & run

Every exercise is self-contained with its own Makefile:

cd Module02/ex02
make
./<program>

Compiled with c++ -Wall -Wextra -Werror -std=c++98.

What I learned

Class design, RAII and the Orthodox Canonical Form, inheritance and polymorphism, exception safety and the differences between C and C++ memory models.