Spendbase interview question

More like a system design system