alphanumeric characters
For unlimited access to Homework Help, a Homework+ subscription is required.
Question 5. [7 MARKS] Part (a) (6 MARKS) Write the body of the following function according to its docstring description. def numeric-phone (alphanumeric_phone, mapping): (str, list of str) -> int Preconditions: - len(mapping) <= 10 - alphanumeric-phone contains only digits and uppercase letters - each letter in alphanumeric_phone is guaranteed to appear in mapping once - mapping may contain letters not in alphanumeric-phone Return a numeric phone number that corresponds to alphanumeric_phone. Each letter from alphanumeric-phone is replaced with the index of the item from mapping that contains the letter. Digits are not replaced. >>> numeric-phone ('416310BELL', ['ABC', 'DEF', 'GHI', 'JKL', 'NO', 'PQRS', 'TUV', 'WXYZ']) 4163100133
8.5.5 practice questions
You use productivity apps on your iPad tablet device while traveling between client sites. You're concerned that you may lose your iPad while on the road and want to protect the data stored on it from being compromised. Currently, your iPad uses a 4-digit PIN number for a passcode. You want to use a more complex alphanumeric passcode. You also want all data on the device to be erased if the wrong passcode is entered more than 10 consecutive times. What should you do?
Ā