GCM Grosvenor Interview Question

Technical portion was a singular leetcode medium problem. Not hard