Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
x = [1];
y = [1];
assert(isequal(individualNumSum(x),y))
w =
1
y =
1
|
2 | Pass |
x = [103];
y = [4];
assert(isequal(individualNumSum(x),y))
w =
4
y =
4
|
3 | Fail |
x=[189 22 39 88 55 485 769 215 3685 4589];
y = [9 4 3 7 1 8 4 8 4 8];
assert(isequal(individualNumSum(x),y))
w =
18
w =
4
w =
12
w =
16
w =
10
w =
17
w =
22
w =
8
w =
22
w =
26
y =
9 4 3 7 10 8 4 8 4 8
|
4 | Fail |
x=[1111 2222 3333 4444 5555 6666 7777 8888 9999 0];
y = [4 8 3 7 2 6 1 5 9 0];
assert(isequal(individualNumSum(x),y))
w =
4
w =
8
w =
12
w =
16
w =
20
w =
24
w =
28
w =
32
w =
36
w =
0
y =
4 8 3 7 2 6 10 5 9 0
|
5 | Pass |
x=[111 222 333 444 555 666 777 888 999 0];
y = [3 6 9 3 6 9 3 6 9 0];
assert(isequal(individualNumSum(x),y))
w =
3
w =
6
w =
9
w =
12
w =
15
w =
18
w =
21
w =
24
w =
27
w =
0
y =
3 6 9 3 6 9 3 6 9 0
|
6 | Pass |
x=[11 3];
y = [2 3];
assert(isequal(individualNumSum(x),y))
w =
2
w =
3
y =
2 3
|
Return the largest number that is adjacent to a zero
3749 Solvers
151 Solvers
Multiples of a Number in a Given Range
214 Solvers
The Answer to Life, the Universe, and Everything
383 Solvers
505 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!