#include <iostream>
#include <limits.h>
using namespace std; // consider removing this line in serious projects
int main() {
int x = INT_MAX;
cout << x << endl;
cout << x+1 << endl << endl;
x = UINT_MAX;
cout << x << endl;
cout << x+1 << endl << endl;
x = INT_MIN;
cout << x << endl;
cout << x-1 << endl << endl;
unsigned int y = UINT_MAX;
cout << y << endl;
cout << y+1 << endl << endl;
y = 0;
cout << y << endl;
cout << y-1 << endl << endl;
cout << stoi("101", nullptr, 2);
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8bGltaXRzLmg+CnVzaW5nIG5hbWVzcGFjZSBzdGQ7IC8vIGNvbnNpZGVyIHJlbW92aW5nIHRoaXMgbGluZSBpbiBzZXJpb3VzIHByb2plY3RzCgppbnQgbWFpbigpIHsKCWludCB4ID0gSU5UX01BWDsKCWNvdXQgPDwgeCA8PCBlbmRsOwoJY291dCA8PCB4KzEgPDwgZW5kbCA8PCBlbmRsOwoJCgl4ID0gVUlOVF9NQVg7Cgljb3V0IDw8IHggPDwgZW5kbDsKCWNvdXQgPDwgeCsxIDw8IGVuZGwgPDwgZW5kbDsKCQoJeCA9IElOVF9NSU47Cgljb3V0IDw8IHggPDwgZW5kbDsKCWNvdXQgPDwgeC0xIDw8IGVuZGwgPDwgZW5kbDsKCQoJdW5zaWduZWQgaW50IHkgPSBVSU5UX01BWDsKCWNvdXQgPDwgeSA8PCBlbmRsOwoJY291dCA8PCB5KzEgPDwgZW5kbCA8PCBlbmRsOwoJCgl5ID0gMDsKCWNvdXQgPDwgeSA8PCBlbmRsOwoJY291dCA8PCB5LTEgPDwgZW5kbCA8PCBlbmRsOwoJCgljb3V0IDw8IHN0b2koIjEwMSIsIG51bGxwdHIsIDIpOwoJCglyZXR1cm4gMDsKfQ==