Use XOR to encode and decode a message

http://ideone.com/90dHdA