1. Write a program that uses input to prompt a user for their name and then welcomes them: #Prompt the user for their name name = input("Enter your name: ") #Print a welcome message with the user's name print("Hello", name, "!", "Welcome to our program.") When you run this program, it will display the message "Enter your name:" in the console. The user can type in their name, and after pressing Enter, the program will print a welcome message using their name. 2. Write a program to prompt the user for hours and rate per hour to compute gross pay. # Prompt the user for the number of hours worked hours = int(input("Enter the number of hours worked: ")) #Prompt the user for the hourly pay rate rate = int(input("Enter the hourly pay rate: ")) # Calculate the gross pay pay = hours * rate #Display the gross pay print("Pay: " pay) In this program, we first use the input function to get the number of hours w...
Expert in Website, Web app, and Software Development.