Cody

Solution 1148342

Submitted on 29 Mar 2017
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
f = '2(x + y)'; y = expandf(f); validatestring(y,{'2 ( x + y )'}) assert(isequal(y,'2 ( x + y )'),'Not that kind of expansion ;)')

Error using TestPoint1 (line 3) Expected input to match one of these values: '2 ( x + y )' The input, '2 ( x + y )', did not match any of the valid values.

2   Fail
f = '2(x + y + z)'; y = expandf(f); validatestring(y,{'2 ( x + y + z )'}) assert(isequal(y,'2 ( x + y + z )'),'Not that kind of expansion ;)')

Error using TestPoint2 (line 3) Expected input to match one of these values: '2 ( x + y + z )' The input, '2 ( x + y )', did not match any of the valid values.