Domanda di colloquio di ServiceNow

Two leetcode easy questions and javascript knowledge