Nth Magical Number Leetcode Javascript Practice Questions