Answers for "how to get rid of all spaces in c++"

C++
1

c++ remove space from string

static std::string removeSpaces(std::string str)
{
	str.erase(remove(str.begin(), str.end(), ' '), str.end());
	return str;
}
Posted by: Guest on March-02-2020

Code answers related to "how to get rid of all spaces in c++"

Browse Popular Code Answers by Language