Search⌘ K
AI Features

Third Maximum Number

Third Maximum Number asks you to return the third distinct maximum value in an integer array, or the overall maximum when fewer than three distinct values exist. Values may be negative.

Statement

Given an integer array, nums, determine and return the third distinct maximum element in the ...