Pergunta de entrevista da empresa Shopify

Coding challenge and follow up questions on approach