This module focuses on templated containers, iterators, algorithms, and custom adaptations of standard containers in C++.
For each exercise, navigate to its folder, compile, and run:
π ex00
cd ex00
make
./ex00
π ex01
cd ex01
make
./ex01
π ex02
cd ex02
make
./ex02
ex00 β Easy find: Write a template function easyfind() that searches for an integer in any integer container. Return the found value or handle not found via exception or error.
ex01 β Span: Implement a Span class storing up to N integers. Provide:
addNumber() to add one number
shortestSpan() and longestSpan() to calculate minimal/maximal differences
A method to add a range of numbers using iterators (for bulk filling, e.g., 10,000+ numbers)
ex02 β Mutated abomination: Create a MutantStack class inheriting from std::stack but exposing iterators (begin() / end()). This makes the stack iterable like standard containers.
If you have any questions or suggestions, feel free to connect: π LinkedIn: Valentina Nguyen πββοΈ
This project was developed and tested on Linux (Ubuntu).