add within

This commit is contained in:
chatlanin
2022-03-02 11:08:14 +03:00
parent d7bff82e02
commit 55a2bacc0e
9 changed files with 64 additions and 4 deletions

View File

@@ -1,11 +1,17 @@
#include <iostream>
#include "string/string.hpp"
#include "range/range.hpp"
int main(int argc, char *argv[])
{
std::string str { "asdf,qwer,zxcv" };
hack::v_str v = hack::split_str(str, ',');
{// ex: split_str
std::string str { "asdf,qwer,zxcv" };
hack::v_str v = hack::split_str(str, ',');
for (const auto& c : v) std::cout << c << std::endl;
}
for (const auto& c : v) std::cout << c << std::endl;
{// ex: within
std::cout << hack::within(12, 34, 12, 23, 31) << std::endl;
}
}