#include #include #include "date.h" #include "sorter.h" using namespace std; int main() { int a1[] = {1, 3, 0, 2, 5}; const size_t n1 = sizeof a1 / sizeof a1[0]; sorter(a1, a1 + n1); for (const int *p = a1; p < a1 + n1; ++p) { cout << *p << "\n"; } cout << "\n"; date a2[] = { date(date::december, 7, 1941), date(date::october, 29, 1929), date(date::july, 4, 1776), date(date::september, 11, 2001), date(date::july, 20, 1969) }; const size_t n2 = sizeof a2 / sizeof a2[0]; sorter(a2, a2 + n2); for (const date *p = a2; p < a2 + n2; ++p) { cout << *p << "\n"; } return EXIT_SUCCESS; }