Tag Info

New answers tagged

0

res = Transpose[{Characters[#], ToCharacterCode[#] - 96}] & ["abcxyz"]; TableForm[res, TableAlignments -> Right, TableDirections -> Row, TableSpacing -> {2, 2}]


4

You can utilize the build in ToCharacterCode together with a shift of -96 for the character conversion and IntegerString to get the leading zero for integers < 10: toInteger[s_String] := IntegerString[ToCharacterCode[s] - 96, 10, 2] E.g.: toInteger["test"] {20, 05, 19, 20} toInteger["abcdez"] {01, 02, 03, 04, 05, 26} To display the letters ...



Top 50 recent answers are included