Domanda di colloquio di Uber

Basic algorithm question (Leetcode medium). One design question and bunch of behavior questions.