Cody

# Problem 1640. COUNT LETTERS

Solution 303374

Submitted on 13 Aug 2013 by James
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   Pass
%% x='The MAtlAb code'; y_correct = ['T 2';'H 1';'E 2';'M 1';'A 2';'L 1';'B 1';'C 1';'O 1';'D 1']; assert(strcmp(your_fcn_name(x),y_correct)==1)

z = THEMATLABCODE y = T 2 y = T 2 H 1 y = T 2 H 1 E 2 y = T 2 H 1 E 2 M 1 y = T 2 H 1 E 2 M 1 A 2 y = T 2 H 1 E 2 M 1 A 2 L 1 y = T 2 H 1 E 2 M 1 A 2 L 1 B 1 y = T 2 H 1 E 2 M 1 A 2 L 1 B 1 C 1 y = T 2 H 1 E 2 M 1 A 2 L 1 B 1 C 1 O 1 y = T 2 H 1 E 2 M 1 A 2 L 1 B 1 C 1 O 1 D 1

2   Pass
%% x='Count The STRINGS'; y_correct =['C 1';'O 1';'U 1';'N 2';'T 3';'H 1';'E 1';'S 2';'R 1';'I 1';'G 1';]; assert(strcmp(your_fcn_name(x),y_correct)==1)

z = COUNTTHESTRINGS y = C 1 y = C 1 O 1 y = C 1 O 1 U 1 y = C 1 O 1 U 1 N 2 y = C 1 O 1 U 1 N 2 T 3 y = C 1 O 1 U 1 N 2 T 3 H 1 y = C 1 O 1 U 1 N 2 T 3 H 1 E 1 y = C 1 O 1 U 1 N 2 T 3 H 1 E 1 S 2 y = C 1 O 1 U 1 N 2 T 3 H 1 E 1 S 2 R 1 y = C 1 O 1 U 1 N 2 T 3 H 1 E 1 S 2 R 1 I 1 y = C 1 O 1 U 1 N 2 T 3 H 1 E 1 S 2 R 1 I 1 G 1