Given a non-empty array of integers nums, return the value that appears most often. If several values tie, return the smallest of them.
Most Frequent Value (Set 7) — the data. This set runs 4 cases: nums holds arrays of 31–41 items, with values from 1 to 5. The hidden cases are the largest of the set.