J.P. Morgan Interview Question

Leetcode medium and one leetcode easy problem