Domanda di colloquio di General Motors (GM)

coding question from leetcode. use this as practice