Maximum Product of Word Lengths
Given a string arraywords
, find the maximum value oflength(word[i]) * length(word[j])
where the two words do not share common letters. You may assume that each word will contain only lower case letters. If no such two words exist, return 0.
Example 1:
Example 2:
Example 3:
Solution
Last updated