#include using namespace std; int main() { string S; cin >> S; S.at(S.size() - 1) = S.at(S.size() - 1) == '0' ? '1' : '0'; cout << S << endl; }