Problem
Ordered radicals
Problem 124
Solution
bruteforce
dictionary
You can define rad function by using prime_division method.
And from 1 to 100000, you can get each of rad value.
If a number’s rad is not included in cache, create new array of the rad value set.
If it is included, just add on the rad value set
After that, you can easily get E(10000)
|
|
Efficiency
O(n^(3/2))