Leetcode Question 2 Difficulty