4 ms·No it doesn't. xor swap works fine when the two values are equal. The problem is when &a == &b.by twtw 8y agoNo it doesn't. xor swap works fine when the two values are equal. The problem is when &a == &b.