#include using namespace std; string f(const string& a){ string res; for (char c : a) { if (islower(c)) { res += toupper(c); } else if (isupper(c)) { res += tolower(c); } else { res += c; } } return res; } int main(){ string s; cin >> s; cout << f(s) << endl; }