How to add a number to an integer like a string
If you want an int as result, multiply with the base: int a = 5; int b = 5; int c = 10 * a + b; // 55 If you want the result to be a std::string, use std::to_string (since C++11): int a = 5; int b = 5; std::string c = std::to_string(a) + … Read more