Cody

# Problem 42673. Longest Collatz Sequence

Solution 3235813

Submitted on 16 Oct 2020
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   Fail
x = 10; assert(isequal(euler14(x),9))

Index exceeds the number of array elements (10). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test1 (line 2) assert(isequal(euler14(x),9))

2   Fail
x = 100; assert(isequal(euler14(x),97))

y = 1

Error using + Too many output arguments. Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test2 (line 2) assert(isequal(euler14(x),97))

3   Fail
x = 96; assert(isequal(euler14(x),73))

y = 1

Error using + Too many output arguments. Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test3 (line 2) assert(isequal(euler14(x),73))

4   Fail
x = 1000; assert(isequal(euler14(x),871))

Index exceeds the number of array elements (1000). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test4 (line 2) assert(isequal(euler14(x),871))

5   Fail
x = 870; assert(isequal(euler14(x),703))

Index exceeds the number of array elements (870). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test5 (line 2) assert(isequal(euler14(x),703))

6   Fail
assert(isequal(euler14(871),871))

Index exceeds the number of array elements (871). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in Test6 (line 1) assert(isequal(euler14(871),871))

7   Fail
x = 77030; assert(isequal(euler14(x),52527))

Index exceeds the number of array elements (77030). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in Test7 (line 2) assert(isequal(euler14(x),52527))

8   Fail
x = 77031; assert(isequal(euler14(x),77031))

Index exceeds the number of array elements (77031). Error in euler14 (line 7) if val(x)==0 Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in Test8 (line 2) assert(isequal(euler14(x),77031))

9   Fail
assert(isequal(euler14(500000),410011))

y = 1

Error using + Too many output arguments. Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val);...

10   Fail
z = 900000; y_correct=837799; assert(isequal(euler14(z),y_correct))

y = 1

Error using + Too many output arguments. Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 11) [~,l] = 1 + euler14(3*x+1,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val); Error in euler14 (line 9) [~, l] = 1 + euler14(x/2,val);...

### Community Treasure Hunt

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

Start Hunting!