This repository contains CounterUint, a small C++ helper class designed for the 42 School cpp-module-09 assignment that implements merge-insertion sort. CounterUint wraps an unsigned int and overloads comparison operators to count comparisons precisely. Use CounterUint as the element type in your containers (e.g., std::vector, std::deque) so that every comparison performed by your sorting algorithm increments an internal counter. After sorting, call getCompareCount() to obtain the exact number of comparisons performed.
akyoshid/counter-uint
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|