Problem 54700. Leyland Primes
Solution Stats
Problem Comments
-
4 Comments
24^5+25^12 in test case 6 is greater than 2^53 and therefore cannot be tested using ordinary double precision numbers.
Tim, William, Chris -
The faulty test case has been edited out of the test suite. Apologies for the inconvenience. Please attempt/edit your answer accordingly.
Dyuman, it looks like Test 6 is still being applied.
I thought commenting it out would work, but it didn't. I have removed it completely and rescored the solutions, good to go.
Do rate the problem!
Solution Comments
-
3 Comments
ismember() is not allowed now!
I expected that! But I really couldn't see why one would write a complicated program when there are just a handful of well-known values.
Dyuman,
I have written a proper solution now, and it works on everything except Test 6. As Tim has pointed out, the argument in that case is larger than flintmax. isprime() evaluates to zero.
Problem Recent Solvers5
Suggested Problems
-
Back to basics 20 - singleton dimensions
265 Solvers
-
Put two time series onto the same time basis
301 Solvers
-
Generate a vector like 1,2,2,3,3,3,4,4,4,4
8159 Solvers
-
58 Solvers
-
10533 Solvers
More from this Author27
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!