#ifndef STRING_H #define STRING_H #include #include #include // Split a string on a delimiter to a vector of strings inline std::vector split(const std::string &str, const char delimiter) { std::vector result; std::stringstream ss(str); std::string token; while (std::getline(ss, token, delimiter)) { result.push_back(token); } return result; } #endif //STRING_H