Duolingo Interview Question

Encode and Decode string.