Problem 53745. Easy Sequences 60: Almost Cube Root
The almost cube root of an integer x, is the largest possible integer r, such that
and
. For example
, then
, since
and since the next larger divisor of
which is 6, does not qualify because
. Obviously, if x is a perfect cube, then
.
Given an integer n, please find sum of the "almost cube roots" of all integers from 1 to
For
, the program ouput should be
:
where:
is the almost cube root of i.
Solution Stats
Problem Comments
-
3 Comments
Tim
on 30 Dec 2021
I am getting s=3771 for n=1000 and ss=[36, 578069405385, 493, 21113, 50479263911] for test 10.
Ramon Villamangca
on 31 Dec 2021
Hi Tim,
You are correct. Please try again and please like and rate the problem. Thanks.
GeeTwo
on 4 Jul 2023
I have a drop dead simple solution (size=33) that runs on time if the max exponent of test case 10 were 8.6, but I can't figure out how to make it any faster, even with more complexity. Based on the motif of ES VII, I suspect prime numbers hold the key, but I don't see how.
Solution Comments
Show commentsProblem Recent Solvers4
Suggested Problems
-
185 Solvers
-
Decrypt the cypher using XOR encryption (for beginners)
45 Solvers
-
Pernicious Anniversary Problem
822 Solvers
-
639 Solvers
-
Determine whether the input is an anagram number
6 Solvers
More from this Author116
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!