Second Most Frequent Element

Company: IBM Backend Developer_24may

Difficulty: medium