Cody

Problem 64. The Goldbach Conjecture, Part 2

Solution 2722296

Submitted on 21 Jul 2020 by Velizar Kirkow
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
n = 6; c_correct = 1; assert(isequal(goldbach2(n),c_correct))

SS = 3 3

2   Pass
n = 10; c_correct = 2; assert(isequal(goldbach2(n),c_correct))

SS = 3 7 5 5

3   Pass
n = 50; c_correct = 4; assert(isequal(goldbach2(n),c_correct))

SS = 3 47 7 43 13 37 19 31

4   Pass
n = 480; c_correct = 29; assert(isequal(goldbach2(n),c_correct))

SS = 13 467 17 463 19 461 23 457 31 449 37 443 41 439 47 433 59 421 61 419 71 409 79 401 83 397 97 383 101 379 107 373 113 367 127 353 131 349 149 331 163 317 167 313 173 307 197 283 199 281 211 269 223 257 229 251 239 241

Suggested Problems

More from this Author95

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!