Cody

Problem 466. Compress strings (not springs)

Solution 1098172

Submitted on 4 Jan 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
x='Blogs , Trendy , Cody , Contest .'; y='Blogs, Trendy, Cody, Contest.'; assert(isequal(cozy_cody(x),y))

x = Blogs , Trendy , Cody , Contest . str2 = Blogs, Trendy, Cody, Contest.

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint1 (line 3) assert(isequal(cozy_cody(x),y))

2   Fail
x='Trendy , Cody , Contest .'; y='Trendy, Cody, Contest.'; assert(isequal(cozy_cody(x),y))

x = Trendy , Cody , Contest . str2 = Trendy, Cody, Contest.

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint2 (line 3) assert(isequal(cozy_cody(x),y))

3   Fail
x='One Two Three Four Five Six Seven Eight Nine Ten'; y='One Two Three Four Five Six Seven Eight Nine Ten'; assert(isequal(cozy_cody(x),y))

x = One Two Three Four Five Six Seven Eight Nine Ten str2 = OneTwoThreeFourFiveSixSevenEightNineTen

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint3 (line 3) assert(isequal(cozy_cody(x),y))

4   Fail
x='1, 2, 3, 4, 5, 6, 7, 8, 9, 10'; y='1, 2, 3, 4, 5, 6, 7, 8, 9, 10'; assert(isequal(cozy_cody(x),y))

x = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 str2 = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint4 (line 3) assert(isequal(cozy_cody(x),y))

5   Fail
x='1 , and 3 , and 7 , and 12'; y='1, and 3, and 7, and 12'; assert(isequal(cozy_cody(x),y))

x = 1 , and 3 , and 7 , and 12 str2 = 1, and3, and7, and12

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint5 (line 3) assert(isequal(cozy_cody(x),y))

6   Fail
x='Hello There !'; y='Hello There!'; assert(isequal(cozy_cody(x),y))

x = Hello There ! str2 = HelloThere!

Output argument "y" (and maybe others) not assigned during call to "cozy_cody". Error in TestPoint6 (line 3) assert(isequal(cozy_cody(x),y))