Question: Username Generator Websites and apps often suggest a username for new users, based upon some details the user provided. Write a function below called username
Username Generator
Websites and apps often suggest a username for new users, based upon some details the user provided. Write a function below called usernamefromname which takes the user's full name, and returns a suggested username. The username should be lowercase, and with all spaces replaced with underscores
For example:
John Smith johnsmith
Maria Fernanda Coro Vargas mariafernandacorovargas
# Write your 'usernamefromname' function here
name 'Alice Adams'
printusernamefromnamename
Improved Username Generator
A better way to suggest a username might be to extract part of their email address. Write a function below called usernamefromemail which takes an email address, then slices and returns the part before the a character. The username should be again be all lowercase you can assume that it is already a valid email address, but that it may have uppercase characters.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
