ServiceNow Interview Question

leetcode easy to medium. fibonacci, 3 sum