fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5.  
  6. // your code goes here
  7.  
  8. unsigned int value = 0xffffffff;
  9. unsigned int len = 32;
  10. printf("0x%x\n", value << len); //will print 0xffffffff
  11. printf("0x%x\n", 0xffffffff << 32); //will print 0x0
  12. return 0;
  13. }
Success #stdin #stdout 0s 3340KB
stdin
Standard input is empty
stdout
0x0
0x0