Question d’entretien chez Squarepoint Capital

leetcode medium question (<1400cf difficulty)