Learn
Practice
Newsletter
Resources
Animations
New
F
Toggle theme
0
F
0
Toggle menu
← Back to All Animations
Ugly Number
Bookmark
Input
Simple Ugly
Power of 2
Not Ugly
One
All Factors
Custom
n
=
6
allowed factors
2
3
5
n =
6
Ugly numbers factor into only 2, 3, and 5
algo
master
.
io
Step:
Start: is n = 6 an ugly number?
0 / 11
Input
Simple Ugly
Power of 2
Not Ugly
One
All Factors
Custom
n
=
6
0 / 11
allowed factors
2
3
5
n =
6
Ugly numbers factor into only 2, 3, and 5
algo
master
.
io
Step:
Start: is n = 6 an ugly number?