Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- using namespace std;
- int main() {
- int a = 55, b = 278;
- cout << showbase << hex << "a = " << a << ", b = " << b << endl;
- a &= b;
- cout << "a = " << a << ", b = " << b << endl;
- b |= a;
- cout << "a = " << a << ", b = " << b << endl;
- a ^= b;
- cout << "a = " << a << ", b = " << b << endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement