Shopify interview question

Write a recursive function in Python