Question
FOR PYTHON Write a PYTHON program that contains a list holding the names of four USA presidents . Use any presidents you wish. Then, run
FOR PYTHON
Write a PYTHON program that contains a list holding the names of four USA presidents. Use any presidents you wish. Then, run aloop that adds four more presidents to the list. Call another function with the list as its sole argument. This second function should sort the list and then loop through the list to print each president's name on its own line.
SAMPLE OUTPUT
Enter the name of another president Jefferson
Enter the name of another president Truman
Enter the name of another president Obama
Enter the name of another president Eisenhower
Here is the presidents list, sorted
Eisenhower
Jefferson
Kennedy
Lincoln
Obama
Truman
Washington
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started