Citadel Interview Question

Online assessment - 2 leetcode mediums