Community
A monotonic stack finds next greater values in one scan — CareerVerse