Problem 42720. Breaking Bad Tiles (Spelling with Element Symbols)

Created by Ned Gulley in Community

Given a word, how you would spell it with element symbols from the periodic table? For instance, if given the string "Paper", you could return these symbols: Pa P Er (Protactinium, Phosphorus, Erbium).

------  ------  ------
| Pa |  | P  |  | Er | 
------  ------  ------

I'll give you a string, and you return a cell-array of strings. The answer is not always unique. I'll check that you use only element symbols, and that when they are glued together they spell the right string.


 'Paper'   => {'Pa','P','Er'}
 'America' => {'Am','Er','I','Ca'}
 'Paige'   => {'Pa','I','Ge'}

The test suite is case-insensitive. Only strings with possible solutions will be supplied.

(Thanks for the idea, Shriram!)

Solution Stats

78.95% Correct | 21.05% Incorrect
Last solution submitted on Mar 30, 2019

Problem Comments

Solution Comments