Question d’entretien chez Google

Simple DSA question, which could be seen from leetcode