Shopify Interview Question

Write a recursive function in Python