Leetcode in java