Simplified XOR operation