DigitalOcean Interview Question

How would you design a URL shortener?