Email generator based on name

Here is a simple email generator based on a name:

Name: [Insert name here]

Email Generator:

  1. Take the first letter of the first name and use it as the first part of the email address.
  2. Take the first letter of the last name and use it as the second part of the email address.
  3. Add a random number between 1 and 100 to the end of the email address to make it unique.

Here is an example:

Name: John Smith

Email Generator:

  1. First letter of first name: J
  2. First letter of last name: S
  3. Random number: 42

Generated Email: [email protected]

Here is a Python code snippet that can generate emails based on a name:

import random

def generate_email(name):
    first_name, last_name = name.split()
    first_letter_first_name = first_name[0].lower()
    first_letter_last_name = last_name[0].lower()
    random_number = random.randint(1, 100)
    email = f"{first_letter_first_name}{first_letter_last_name}{random_number}@example.com"
    return email

name = input("Enter your name: ")
email = generate_email(name)
print(f"Generated email: {email}")

You can run this code and enter your name to generate an email address. Note that this is a very basic email generator and you may want to add more complexity to it (e.g., checking if the generated email is already in use, using a more sophisticated random number generator, etc.).