Cody

# Problem 3048. Scrabble Scores - 3

Solution 2077955

Submitted on 3 Jan 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
word = 'matlab'; mult = {'','DW','','','','DL'}; score = 26; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test1 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

2   Fail
word = 'problem'; mult = {'','','','','','',''}; score = 13; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test2 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

3   Fail
word = 'zither'; mult = {'','DW','','','','DW'}; score = 72; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test3 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

4   Fail
word = 'quandry'; mult = {'TL','','','','TL','',''}; score = 44; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test4 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

5   Fail
word = 'concatenates'; mult = {'TW','','','DL','','','','TW','','','','DL'}; score = 180; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test5 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

6   Fail
word = 'heterogeneousness'; mult = {'QW','','','DL','','','','TW','','','DL','','','TW','','',''}; score = 828; assert(isequal(scrabble_scores_3(word,mult),score))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test6 (line 4) assert(isequal(scrabble_scores_3(word,mult),score))

7   Fail
word = {'hello','donut','cheat','shape','quote'}; mult = {'QW','','','DL',''}; score = [36 28 44 52 60]; ind = randi(5); assert(isequal(scrabble_scores_3(word{ind},mult),score(ind)))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test7 (line 5) assert(isequal(scrabble_scores_3(word{ind},mult),score(ind)))

8   Fail
word = {'hello','donut','cheat','shape','quote'}; mult = {'QL','','','','DW'}; score = [40 24 38 26 88]; ind = randi(5); assert(isequal(scrabble_scores_3(word{ind},mult),score(ind)))

Brace indexing is not supported for variables of this type. Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) || isstruct(c{1}) Error in scrabble_scores_3 (line 3) x = cell2mat(word(w)); Error in Test8 (line 5) assert(isequal(scrabble_scores_3(word{ind},mult),score(ind)))