Practice Find the Maximum Factor Score of Array
Read the task, work through the examples, and check your approach against the constraints. Use the original LeetCode task for coding and submissions.
Problem Statement
You are given an integer array nums. The factor score of an array is defined as the product of the LCM and GCD of all elements of that array. Return the maximum factor score of nums after removing at most one element from it. Note that both the LCM and GCD of a single number are the number itself, and the factor score of an empty array is 0.
Source: Find the Maximum Factor Score of Array on LeetCode. Use the original task for its coding environment and submissions.
Examples
# Example 1
nums = [2,4,8,16]
64
# Example 2
nums = [1,2,3,4,5]
60
# Example 3
nums = [3]
9
Constraints
Related LeetCode Problems
Practice more problems similar to Find the Maximum Factor Score of Array.
Review your practice with PhantomCodeAI
After trying the problem yourself, use the app to discuss your approach, complexity, and edge cases.