Lock And Key Problem Leetcode