fork download
  1. #include <stdio.h>
  2. #include <stdint.h>
  3.  
  4. int main(void)
  5. {
  6. uint16_t skipct, xskipct;
  7.  
  8. for (skipct = 0, xskipct = 0; skipct < 32; skipct++)
  9. {
  10. xskipct ^= skipct;
  11. printf("%3d: %d\n", skipct, xskipct);
  12. }
  13.  
  14. return 0;
  15. }
  16.  
Success #stdin #stdout 0s 5324KB
stdin
Standard input is empty
stdout
  0: 0
  1: 1
  2: 3
  3: 0
  4: 4
  5: 1
  6: 7
  7: 0
  8: 8
  9: 1
 10: 11
 11: 0
 12: 12
 13: 1
 14: 15
 15: 0
 16: 16
 17: 1
 18: 19
 19: 0
 20: 20
 21: 1
 22: 23
 23: 0
 24: 24
 25: 1
 26: 27
 27: 0
 28: 28
 29: 1
 30: 31
 31: 0