blob: e06235b8d1129b51332377c1f2cb62e4c64466b4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#include<bits/stdc++.h>
using namespace std;
int main(){
int n, x=pow(2, 31) - 1;
cin >> n;
cout << n ^ x;
// 0 0 -> 1 -> 0
// 1 1 -> 0 -> 1
// 1 1 -> 0 -> 1
// 1 1 -> 0 -> 0
return 0;
}
|