Cody

Problem 1981. Time and Variable mapping and matching

Solution 549996

Submitted on 26 Dec 2014
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={'0','a','1','', ''; '1','b','2','', ''; '2','', '','c', '3'; '3','', '','d', '4'; '4','e','1','', ''; '5','', '','d', '6'}; Time=[0;1;2;3;4;5]; a=[1;1;1;1;1;1]; b=[0;2;2;2;2;2]; c=[0;0;3;3;3;3]; d=[0;0;0;4;4;6]; e=[0;0;0;0;1;1]; y_correct=[Time;a;b;c;d;e]; [Time,a,b,c,d,e]=your_fcn_name(X); assert(isequal([Time;a;b;c;d;e],y_correct));

Error: Undefined function 'eq' for input arguments of type 'cell'.

2   Fail
%% X={'0','a','1','', ''; '1','a','2','b', '1'; '2','', '','c', '3'; '3','c','4','d', '4'; '4','b','4','', ''; '5','', '','e', '6'}; Time=[0;1;2;3;4;5]; a=[1;2;2;2;2;2]; b=[0;1;1;1;4;4]; c=[0;0;3;4;4;4]; d=[0;0;0;4;4;4]; e=[0;0;0;0;0;6]; y_correct=[Time;a;b;c;d;e]; [Time,a,b,c,d,e]=your_fcn_name(X); assert(isequal([Time;a;b;c;d;e],y_correct));

Error: Undefined function 'eq' for input arguments of type 'cell'.

Suggested Problems

More from this Author10

Community Treasure Hunt

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

Start Hunting!