Cody

Solution 1872341

Submitted on 12 Jul 2019
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 = 'Try this one'; y_correct = rand(1); assert(isequal(assertYourself(x),y_correct))

Assertion failed.

2   Fail
clear all; x = rand(10); y_correct = rand(1); assertYourself(); assert(isequal(true,false))

Assertion failed.

3   Fail
clear all; x = rand(10); y = assertYourself(x,'blah') y_correct = rand(1); assert(isequal(y,y_correct))

y = 0.1319 0.5032 0.9710 0.3507 0.3024 0.1296 0.7271 0.9825 0.9483 0.5710 0.3858 0.7730 0.0711 0.0786 0.8654 0.5008 0.8030 0.0723 0.7397 0.6138 0.7071 0.8660 0.5670 0.4968 0.2356 0.5559 0.4057 0.4964 0.9398 0.5676 0.0889 0.1841 0.3847 0.7093 0.9720 0.3694 0.7031 0.6382 0.7111 0.1354 0.0264 0.5823 0.0212 0.7752 0.0453 0.8066 0.8437 0.0095 0.9231 0.3637 0.9240 0.4927 0.6437 0.8360 0.4251 0.5529 0.6448 0.8644 0.3228 0.0892 0.1461 0.0836 0.1274 0.6884 0.7626 0.1685 0.7491 0.1840 0.6822 0.6665 0.2287 0.4162 0.9878 0.6006 0.4734 0.1037 0.1967 0.6858 0.8872 0.2046 0.9453 0.4431 0.2216 0.3003 0.9922 0.8202 0.2785 0.3106 0.1031 0.8292 0.5084 0.4226 0.7418 0.4254 0.8950 0.0589 0.3999 0.7551 0.1924 0.2398

Assertion failed.

4   Fail
clear all; x = randi(26,10); y_correct = rand(1); [v,z]= assertYourself(x,x,x); z; msg = ['That is not even fair! ',char(randi(26,1,10)+'A')] assert(isequal(x,y_correct));

msg = 'That is not even fair! WWQSHJQMZQ'

Assertion failed.

5   Fail
clear all; [v,z]= assertYourself(); v; assert(false);

Output argument "varargout{1}" (and maybe others) not assigned during call to "assertYourself". Error in Test5 (line 2) [v,z]= assertYourself();

Suggested Problems

More from this Author2