Some numbers (such as 4) have reciprocals with terminating decimal expansions, while others (such as 7) do not. Write a function that counts the numbers less than or equal to the input number whose reciprocals have terminating decimal expansions. For example, given 10, your function should return a count of 6, which corresponds to 1, 2, 4, 5, 8, and 10.

Solution Stats

29 Solutions

16 Solvers

Last Solution submitted on Jul 15, 2026

Last 200 Solutions

Problem Comments

Solution Comments

Show comments
Loading...