fix max and range
This commit is contained in:
42
bin/main.cpp
42
bin/main.cpp
@@ -3,8 +3,8 @@
|
||||
|
||||
#include "hack/logger/logger.hpp"
|
||||
|
||||
#include "hack/mt/algorithms/sort.hpp"
|
||||
#include "hack/mt/algorithms/max.hpp"
|
||||
#include "hack/range/sort.hpp"
|
||||
#include "hack/math/max.hpp"
|
||||
|
||||
#include "hack/patterns/ring_buffer.hpp"
|
||||
|
||||
@@ -25,23 +25,23 @@ auto main(int argc, char *argv[]) -> int
|
||||
hack::log()(v);
|
||||
}
|
||||
|
||||
// // mt::sort
|
||||
// {
|
||||
// std::vector<int> v { 4, 4, 6, 1, 4, 3, 2 };
|
||||
// std::forward_list<int> l { 8, 7, 5, 9, 0, 1, 3, 2, 6, 4 };
|
||||
//
|
||||
// hack::mt::algorithms::sort(v);
|
||||
// hack::mt::algorithms::sort(l);
|
||||
//
|
||||
// hack::log()(v);
|
||||
// hack::log()(l);
|
||||
// }
|
||||
//
|
||||
// // mt::max
|
||||
// {
|
||||
// int a = 4, b = 5;
|
||||
// int& c = a;
|
||||
// hack::log()(hack::mt::algorithms::max(4, 5));
|
||||
// hack::log()(hack::mt::algorithms::max(c, b));
|
||||
// }
|
||||
// range::sort
|
||||
{
|
||||
std::vector<int> v { 4, 4, 6, 1, 4, 3, 2 };
|
||||
std::forward_list<int> l { 8, 7, 5, 9, 0, 1, 3, 2, 6, 4 };
|
||||
|
||||
hack::range::sort(v);
|
||||
hack::range::sort(l);
|
||||
|
||||
hack::log()(v);
|
||||
hack::log()(l);
|
||||
}
|
||||
|
||||
// math::max
|
||||
{
|
||||
int a = 4, b = 5;
|
||||
int& c = a;
|
||||
hack::log()(hack::math::max(4, 5));
|
||||
hack::log()(hack::math::max(c, b));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user