added xor swap