Very EASY java solution
class Solution {\n    public int maxProduct(int[] nums) {\n        Arrays.sort(nums);\n        return ((nums[nums.length-1]-1)*(nums[nums.length-2]-1));\n    }\
class Solution {\n    public int maxProduct(int[] nums) {\n        Arrays.sort(nums);\n        return ((nums[nums.length-1]-1)*(nums[nums.length-2]-1));\n    }\n}
['Java']