Find the sum of all positive integers $n$ such that exactly $2\%$ of the numbers in the set $\{1, 2, \ldots, n\}$ are perfect squares.

Let's think step by step and output the final answer within \boxed{}.
user