#include <iostream>
#include <string>
#include <locale>
#include <cctype>

std::string convertString(std::string s)
{
    for(std::string::iterator it = s.begin(); it != s.end(); ++it)
    {
        if     (isupper(*it)) *it = tolower(*it);
        else if(islower(*it)) *it = toupper(*it);
        else if(isdigit(*it))
        {
            //write code here...
        }
    }
    return s;
}

int main()
{
    std::cout << "Input string to convert: " << std::flush;
    std::string toconvert;
    std::getline(std::cin, toconvert);
    std::cout << "Converted string: " << convertString(toconvert) << std::endl;
}