Question: Write a function called findUserName that displays a suggested username based on a person's first name, last name, and a random number between 1-5 given

 Write a function called findUserName that displays a suggested username based

Write a function called findUserName that displays a suggested username based on a person's first name, last name, and a random number between 1-5 given as a single string "randomNumber firstname lastname" (each separated by a single space, may contains both upper and lower case letters). The result should be the person's first name initial in uppercase, followed by the last name (all the letters in lower) and the multiplication ofrandom number and number of characters of the last name. Note: Steps of findUserName function can be given as follows: def findUserName (s) 1. Separate random number, first name and last name from string s 2. upperFirstInitialFirst letter of the first name in uppercase. 4. num -Integer value of random numberNumber of characters in 5. Concatenate the substring in the order, upperFirstInitial, lowerLast and string value of num and display the result

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!