# fill in a table with some words letters

I have a list of words

list={"ingenuous", "forgotten", "tree", "supercomput", "hundred"}


How can I put the letters of each word in an element of a table such as here:

• You misspelled "ingenious". In any event: have you seen Characters[]? Jul 8, 2016 at 12:16
• Better answers are given, but here is quick one: TableForm[Characters /@ list, TableHeadings -> {list, None}] . Jul 8, 2016 at 12:31
• @AntonAntonov Note that TableForm cannot set gridding line. :)
– yode
Jul 8, 2016 at 12:42
• @yode I know, that is why I said there are better solutions... Also, I think TableForm is under-appreciated, that is why I provided a line with it. Jul 8, 2016 at 12:49

list = {"ingenious", "forgotten", "tree", "supercomput", "hundred"};
list /. word_String :> Join[{word}, Characters@word] // Grid[#, Dividers -> All] &


• This is a winning answer I think. :)
– yode
Jul 8, 2016 at 12:34
• If one is not deterred by /., :>,@, //, #& and friends this style of writing mathematica code is imho the most readable of all. Jul 8, 2016 at 12:36
• I'd have done Prepend[Characters[word], word] myself. Jul 8, 2016 at 13:11
• Another possibility is using {word} ~Join~ Characters@word. Sometimes (not necessarily in this case) infix notation helps to further convey what the particular line of code does (precedence becomes somewhat difficult to assess though) Jul 8, 2016 at 15:20

As the promp of Sascha's answer,I simplify this code be

list={"ingenuous","forgotten","tree","supercomput","hundred"};
Grid[Join[List/@list,Characters/@list,2],Frame->All,Spacings->{2.6,0.5}]