Repeated Number Leetcode Javascript 30