Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
x = rand(1,10);
actual = everyOther(x);
expected = x(1:2:length(x));
assert(isequal(actual, expected))
|
2 | Pass |
x = rand(1,100);
actual = everyOther(x);
expected = x(1:2:length(x));
assert(isequal(actual, expected))
|
3 | Pass |
x = ['A' 'long' 'time' 'ago' 'in' 'a' 'galaxy' 'far' 'far' 'away'];
actual = everyOther(x);
expected = x(1:2:length(x));
assert(isequal(actual, expected))
|
17120 Solvers
Program an exclusive OR operation with logical operators
639 Solvers
Get the length of a given vector
3559 Solvers
Given a window, how many subsets of a vector sum positive
743 Solvers
Are all the three given point in the same line?
270 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!