Design a URL Shortener | Hackerrank Interview Question