We call it an ugly number if a positive integer can be written as $2^a3^b$, where $a,b$ are non-negative integers. Prove that the interval $(n^2,(n+1)^2),n\in\mathbb{N}^*$ has at most $2$ such numbers.
I tried to count the number in the interval $[1,N]$ of such numbers by inclusion and exclusion principle, $$ s(N)=\sum_{k\ge1,(k,2)=(k,3)=1}\mu(k)\left[\frac{N}{k}\right], $$ but it's very hard to make proper estimations.
Though the problem maybe a simple task, but it had really bothered me for a long period. Could you offer me some hints so that I can proceed? Thanks for your help.