1. Write a Python program named LastnameFirstname07.py, using your last name and your first name, that does the following:
2. Be sure to add comments for each section of your code.
3. All code should be in a function, aside from import statements and calling the main function. Call main() only once.
4. Make sure your output is descriptive. Tell the user what you're printing, don't just print out the answers alone.
5. Your program should not use code/concepts we have not yet covered. You must demonstrate that you have mastered the concepts covered.
This is an example of what your program should output:
>>>
=============== RESTART: ManuelNikki07.py ===============
Hi, there! What's your name?
Jenny
Nice to meet you, Jenny!
Check out my super cool program. Here are 3 things it can do!
1. Generate a random number between x and y
2. Print the COOLEST sentence you'll ever read in your life
3. Switch the letters of your first and last name to give you a funny name
Which would you like to do? (Enter 1, 2, or 3)
3
Option 3! Sounds great!
First, please enter your first name: Mark
Now, please enter your last name: Brown
I'm going to switch the letters of your first and last name to give you a funny name!
Your new name is....... Mark Brown
HAHA! Isn't that hilarious?
Thanks for using my program! Bye!
>>>
This is another example of what your program should output:
>>>
=============== RESTART: ManuelNikki07.py ===============
Hi, there! What's your name?
Jen
Nice to meet you, Jen!
Check out my super cool program. Here are 3 things it can do!
1. Generate a random number between x and y
2. Print the COOLEST sentence you'll ever read in your life
3. Switch the letters of your first and last name to give you a funny name
Which would you like to do? (Enter 1, 2, or 3)
100
Error! There's no such thing as option 100!
Please restart the program to try again.
>>>
This is another example of what your program should output:
>>>
=============== RESTART: ManuelNikki07.py ===============
Hi, there! What's your name?
Mike
Nice to meet you, Mike!
Check out my super cool program. Here are 3 things it can do!
1. Generate a random number between x and y
2. Print the COOLEST sentence you'll ever read in your life
3. Switch the letters of your first and last name to give you a funny name
Which would you like to do? (Enter 1, 2, or 3)
one, please! :)
Error! You needed to type in a number value! For example: 1
Please restart the program to try again.
>>>