Juniper Networks Interview Question

They ask Leetcode hard question