where is the problem here? It works on matlab.
the problem is that you cannot change the function name, try to use meanOfPrimes and it will work!
Test | Status | Code Input and Output |
---|---|---|
1 | Fail |
%%
x = 3;
y_correct = 3;
assert(isequal(meanOfPrimes(x),y_correct))
Error: Undefined function 'meanOfPrimes' for input arguments of type 'double'.
|
2 | Fail |
%%
x = [1 2 3];
y_correct = 2.5;
assert(isequal(meanOfPrimes(x),y_correct))
Error: Undefined function 'meanOfPrimes' for input arguments of type 'double'.
|
3 | Fail |
%%
x = [3 3; 3 3];
y_correct = 3;
assert(isequal(meanOfPrimes(x),y_correct))
Error: Undefined function 'meanOfPrimes' for input arguments of type 'double'.
|
4 | Fail |
%%
x = [7 3 8 8]';
y_correct = 5;
assert(isequal(meanOfPrimes(x),y_correct))
Error: Undefined function 'meanOfPrimes' for input arguments of type 'double'.
|
3652 Solvers
Convert a vector into a number
442 Solvers
Output any real number that is neither positive nor negative
252 Solvers
ベクトル [1 2 3 4 5 6 7 8 9 10] の作成
198 Solvers
207 Solvers