Tap here to switch tabs
Problem
Submissions

Problem: Find the Maximum Factor Score of Array

Try to solve the Find the Maximum Factor Score of Array problem.

Statement

You are given an array of integers nums.

The factor score of an array is defined as the product of the greatest common divisor ($ ext{GCD})andtheleastcommonmultiple() and the least common multiple ( ext{LCM}$) of all its elements.

Return the maximum factor score of nums after removing at most 11 element from the array.

Note: The factor score of an empty array is 00. Both the $ ext{GCD}$ and $ ext{LCM}$ of an array with a single element are equal to that element.

Constraints:

  • 1≤1 \leq nums.length ≤100\leq 100

  • 1≤1 \leq nums[i] ≤30\leq 30

⋮
Tap here to switch tabs
Problem
Submissions

Problem: Find the Maximum Factor Score of Array

Try to solve the Find the Maximum Factor Score of Array problem.

Statement

You are given an array of integers nums.

The factor score of an array is defined as the product of the greatest common divisor ($ ext{GCD})andtheleastcommonmultiple() and the least common multiple ( ext{LCM}$) of all its elements.

Return the maximum factor score of nums after removing at most 11 element from the array.

Note: The factor score of an empty array is 00. Both the $ ext{GCD}$ and $ ext{LCM}$ of an array with a single element are equal to that element.

Constraints:

  • 1≤1 \leq nums.length ≤100\leq 100

  • 1≤1 \leq nums[i] ≤30\leq 30