Minimum Common Value Leetcode