News for hackers. Stuff that matters.
Re:That XOR Trick (2020) by danbruc on Thursday July 03, 2025 @10:59AM (#44455749)
Combining two consecutive integers starting with an even one yields one.

  xxxxxxx0 ^ xxxxxxx1 = 00000001 
If we start at a number divisible by four and do this twice, we get one twice.

  xxxxxx00 ^ xxxxxx01 = 00000001
  xxxxxx10 ^ xxxxxx11 = 00000001
And combining the two of course yields zero and we are right back at the start.

There are no comments on this comment yet.