Confusion about the Third Maximum Number

I am really confused about how 2 is the correct answer?
https://leetcode.com/explore/learn/card/fun-with-arrays/523/conclusion/3231/

image

Any explanation would be greatly appreciated.

Thanks

Comments (2)