1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Anna35 [415]
4 years ago
7

Search the web to discover the 10 most common user-selected passwords, and store them in an array. Design a program that prompts

a user for a password, and continue to prompt the user until the user has not chosen one of the common passwords.
Computers and Technology
1 answer:
Airida [17]4 years ago
7 0

Answer:

userpassword = {"123456",

"password",

"123456789",

"12345678",

"12345",

"111111",

"1234567",

"sunshine",

"qwerty",

"abc123"}

#We define the function that prompts the user for a password

def user_passinput():

   password = input("Choose enter a password: ")

   return password

#Function that checks the password

def check_password():

   count = 0

   check_pass = user_passinput()

   if check_pass in userpassword:

       print("Yay!! you entered the correct password")

   elif count <10:

           count = count+1

           print("Please try again")

          user_passinput()

   else:

       print ("Maximum tries exceeded")

check_password()

Explanation:

Using Python for this code, in the first line of the code, we list the dictionary of 10 most common passwords searched on the web. In line 12, we define the function that will demand the user to enter a password and return the value the user entered. Line 16 defines the function that checks if the password is common and prints to the screen either "Yay!! you entered the correct password", "Please try again" or "Maximum tries exceeded" depending on the condition that is satisfied. The last line of the code calls the check_password() function, which actually initiates the designed program.

You might be interested in
Why is it now difficult for computer technology to maintain the pace of
KatRina [158]

It now difficult for computer technology as manufacturing cannot keep up with overwhelming transistor demand.

<h3>What was Moore's Law ?</h3>

Moore's Law is the one that talks about the fact that the number of transistors on a microchip is one that often goes up about two years always, even if the cost of computers is reduced.

Based on the above, It now difficult for computer technology as manufacturing cannot keep up with overwhelming transistor demand.

Learn more about computer technology  from

brainly.com/question/24912812

#SPJ1

6 0
2 years ago
You cannot advance slides during the slide show by pressing the PAGE DOWN key
noname [10]
<span>You cannot advance slides during the slide show by pressing the PAGE DOWN key.
This is a true statement.
</span>
4 0
3 years ago
The amount of time taken by each of 10 students in a class to complete an exam is an example of what type of data? a. Cannot be
vekshin1

Answer:d) Quantitative data

Explanation: Quantitative data is the data that is required for the measurement of count and then exhibited in the numeric values.It is expressed through the type of name, number,code, symbol etc. It is used in the questionnaire, surveys, interviews etc.

Other options are incorrect because time series data is data according to the time event and categorical data is based on the categories of event.Thus, the correct option is option(d).

8 0
3 years ago
Which Ribbon contains the paragraph attributes?<br><br> Home<br> Insert<br> Review<br> View
Lemur [1.5K]
The Home ribbon contains the Paragraph attributes
7 0
3 years ago
Read 2 more answers
Why should cloud computing not be a set of silos? Provide real or made up examples of why incompatible solutions will fail in IT
lesya [120]
2 is tha answer to Why should cloud computing not be a set of silos? Provide real or made up examples of why incompatible solutions will fail in IT.?
8 0
3 years ago
Other questions:
  • In the 2007/2010 version of Paint, which of the following tools are located in the View tab? (Select all that apply.)
    5·1 answer
  • Provide Java code to illustrate how to create an array, reference an array, and address an element of an array.
    13·1 answer
  • A. true
    6·1 answer
  • Which password is an ideal and secure password?
    6·2 answers
  • When projecting a presentation on a large screen, what should your minimum font size be?
    6·2 answers
  • Constructors have the same name as the ____.1. data members2. member methods3. class4. package
    5·1 answer
  • A computer is a multipurpose device that accepts input, processes data, stores data, and produces output, all according to a ser
    9·1 answer
  • The first numerical control machine tool was demonstrated in 1952 in the United States at the Massachusetts Institute of Technol
    14·1 answer
  • Corey set up his presentation for delivery to his team.
    8·1 answer
  • Help me!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!​
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!