Question: Create a program to get a list of lines, and see if any two (or more) lines are the same. Continue to get lines of

Create a program to get a list of lines, and see if any two (or more) lines are the same. Continue to get lines of text until a blank line is given. At the end, then report a single statement if there were duplicate lines or not.

To make this match the solution, use the input() method without a prompt.

Create a program to get a list of lines, and see if

1 2 3 # 4 # create a program to get a list of lines, and 5 # see if any two or more) lines are the same. Continue to get 6 # lines of text until a blank line is given. At the end, then report 7 # a single statement if there were duplicate lines or not. 8 # 9 # To make this assignment match the solution, use the input() method 10 # without a prompt. 11 # 12 # 13 14 15 16 17 if (has_dups): 18 print("The list has duplicate items") 19 else: 20 print("The list does not have duplicate items") #

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!