Question d’entretien chez Atlassian

Hackerank, about leetcode easy-medium difficulty