Easiest Javascript solution - O(n)
\n/**\n * @param {number[]} nums\n * @return {number}\n */\nvar smallestEqual = function(nums) {\n    return nums.findIndex((n, i) => i % 10 === n)\n};\n
```\n/**\n * @param {number[]} nums\n * @return {number}\n */\nvar smallestEqual = function(nums) {\n    return nums.findIndex((n, i) => i % 10 === n)\n};\n```
['JavaScript']