Cody

Solution 3610990

Submitted on 10 Nov 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   Pass

2   Fail
v1 = [1 4]; v2 = [3 8 6 1]; v3_correct = [3 8 7 5]; assert(isequal(vadd(v1,v2),v3_correct)) assert(isequal(vadd(v2,v1),v3_correct))

ans = '14' v2 = 3 8 6 1

Assertion failed.

3   Fail
v1 = [9 9]; v2 = [9 9]; v3_correct = [1 9 8]; assert(isequal(vadd(v1,v2),v3_correct)) assert(isequal(vadd(v2,v1),v3_correct))

ans = '99' v2 = 9 9

Assertion failed.

4   Fail
v1 = [9 4 2 3 5 6 7 3 3 5 5 4 6 3 2 4 2 5 7 7 8 5 4 3 4 7 8 7]; v2 = [3 5 7 3 4 5 2 5 4 8 7 6 4 3 7 8 9 5 4 0 3 2 7 9 0 3 2 8 9]; v3_correct = [4 5 1 5 8 0 9 2 8 2 3 1 9 0 1 1 3 7 9 8 1 1 3 3 3 8 0 7 6]; assert(isequal(vadd(v1,v2),v3_correct)) assert(isequal(vadd(v2,v1),v3_correct))

ans = '9423567335546324257785434787' v2 = 3 5 7 3 4 5 2 5 4 8 7 6 4 3 7 8 9 5 4 0 3 2 7 9 0 3 2 8 9

Assertion failed.

### Community Treasure Hunt

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

Start Hunting!