Stripe interview question

A Data Structure question