Capital One interview question

Leetcode, 2 easy, 2 medium