Cody

Solution 447132

Submitted on 29 May 2014 by rifat
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
%% x =4000000 y_correct = 4613732; assert(isequal(euler002(x),y_correct))

x = 4000000 f = Columns 1 through 8 0 1 1 2 3 5 8 13 Columns 9 through 16 21 34 55 89 144 233 377 610 Columns 17 through 24 987 1597 2584 4181 6765 10946 17711 28657 Columns 25 through 32 46368 75025 121393 196418 317811 514229 832040 1346269 Columns 33 through 35 2178309 3524578 5702887

2   Pass
%% x =97455000 y_correct = 82790070; assert(isequal(euler002(x),y_correct))

x = 97455000 f = Columns 1 through 8 0 1 1 2 3 5 8 13 Columns 9 through 16 21 34 55 89 144 233 377 610 Columns 17 through 24 987 1597 2584 4181 6765 10946 17711 28657 Columns 25 through 32 46368 75025 121393 196418 317811 514229 832040 1346269 Columns 33 through 40 2178309 3524578 5702887 9227465 14930352 24157817 39088169 63245986 Column 41 102334155

3   Pass
%% x =597455000 y_correct = 350704366; assert(isequal(euler002(x),y_correct))

x = 597455000 f = Columns 1 through 8 0 1 1 2 3 5 8 13 Columns 9 through 16 21 34 55 89 144 233 377 610 Columns 17 through 24 987 1597 2584 4181 6765 10946 17711 28657 Columns 25 through 32 46368 75025 121393 196418 317811 514229 832040 1346269 Columns 33 through 40 2178309 3524578 5702887 9227465 14930352 24157817 39088169 63245986 Columns 41 through 45 102334155 165580141 267914296 433494437 701408733

4   Pass
%% x =666576 y_correct = 257114; assert(isequal(euler002(x),y_correct))

x = 666576 f = Columns 1 through 8 0 1 1 2 3 5 8 13 Columns 9 through 16 21 34 55 89 144 233 377 610 Columns 17 through 24 987 1597 2584 4181 6765 10946 17711 28657 Columns 25 through 31 46368 75025 121393 196418 317811 514229 832040