I want to check if a char (string.at(i)) is whitespace in C++. How can I do this easily?
I got this code example, and I was thinking to change the _____ with something, but don’t know what. I’ve tried with ' ', but that didn’t work.
for(int i = 0; i < string.length(); i++)
{
if(string.at(i) == _________)
{
//do something
}
}
1 Answer