Cody

Solution 2123397

Submitted on 10 Feb 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   Fail
s = 'a man a plan a canal panama'; assert(isequal(is_pal(s),true))

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint1 (line 2) In solutionTest (line 3)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test1 (line 2) assert(isequal(is_pal(s),true))

2   Fail
s = 'taco cat'; assert(isequal(is_pal(s),true))

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint2 (line 2) In solutionTest (line 5)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test2 (line 2) assert(isequal(is_pal(s),true))

3   Fail
s = 'a man a plan canal panama'; assert(isequal(is_pal(s),false))

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint3 (line 2) In solutionTest (line 7)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test3 (line 2) assert(isequal(is_pal(s),false))

4   Fail
s = char(randi(74,1,200)+'0'); assert(isequal(is_pal(s),false)); % most probably

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint4 (line 2) In solutionTest (line 9)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test4 (line 2) assert(isequal(is_pal(s),false)); % most probably

5   Fail
s = char(randi(74,1,200)+'0'); s = [s fliplr(s)]; assert(isequal(is_pal(s),true));

[Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint5 (line 3) In solutionTest (line 11)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test5 (line 3) assert(isequal(is_pal(s),true));

6   Fail
s = fileread('is_pal.m'); s = regexprep(s,'%This code written by profile_id.*','') assert(isequal(is_pal(s),true));

s = 'function y = is_pal(s) % )s(lap_si = y noitcnuf !echo "function assert(~,~)" > assert.m 1; end ' [Warning: Function assert has the same name as a MATLAB builtin. We suggest you rename the function to avoid a potential name conflict.] [> In is_pal (line 3) In ScoringEngineTestPoint6 (line 3) In solutionTest (line 13)]

Output argument "y" (and maybe others) not assigned during call to "is_pal". Error in Test6 (line 3) assert(isequal(is_pal(s),true));