Generation

generate functionThu, 26 Jan 2023

how to convert the last 3 characters on a string into an int

int num = std::stoi(str.substr(str.size()-3, 3))

Want to kickstart your project?Use the new AI Studio to create your code