#include #include std::string operator*(std::string const& str, int n) { std::string ret{}; for (int i{}; i < n; ++i) { ret += str; } return ret; } int main() { std::string hello{"Hej"}; std::cout << hello*5 << std::endl; }