#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
(n % 2 == 0 || n == 1) && (cout << n/2);
!(n % 2 == 0 || n == 1) && (cout << n);
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKaW50IG1haW4oKSB7CiAgICBpbnQgbjsKICAgIGNpbiA+PiBuOwogICAgKG4gJSAyID09IDAgfHwgbiA9PSAxKSAmJiAoY291dCA8PCBuLzIpOwogICAgIShuICUgMiA9PSAwIHx8IG4gPT0gMSkgJiYgKGNvdXQgPDwgbik7CiAgICByZXR1cm4gMDsKfQ==