I have to make this program that receives a coded string and returns the normal text. For example:
input = 42 32 53 53 63 *43 *21 61 *61 21 73 52
output = hello i am mark
I have this dictionary with the equivalences:
keypad= {'21': 'a', '22': 'b', '23': 'c', '31': 'd', '32': 'e', '33': 'f', '41': 'g', '42': 'h', '43': 'i',
'51': 'j', '52': 'k', '53': 'l', '61': 'm', '62': 'n', '63': 'o', '71': 'p', '72': 'q', '74': 'r',
'74': 's', '81': 't', '82': 'u', '83': 'v', '91': 'w', '93': 'x', '93': 'y', '94': 'z', '*': ' '}
I need to use it as it is. I think I need to iterate each number and get the key in the dictionary and add it to an empty string, but I have no idea on how to do it. If anyone has an idea I'd be really thankful.