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
stiv31 [10]
3 years ago
7

Use a for/else loop to traverse through the key names in the dictionary below in order to find Mr. Potatohead’s mailing address.

The key name is his social security number. Once you find his SSN (key-name), you can display its value by using the following function:
print (Dictary.get(123-45-6789))

If the key you are looking for does not exist, your code should break out of the loop and display the following message: “Key not found”

Dictary = {
'code':6734,
'dept': 'sales',
123-45-6789:"Mr.Potato Head \n234 Potato Lane \nPotato Chip, ID 77725"
}
Computers and Technology
1 answer:
Tatiana [17]3 years ago
4 0

Dictary = {

'code':6734,

'dept': 'sales',

123-45-6789:"Mr.Potato Head \n234 Potato Lane \nPotato Chip, ID 77725"

}

for i in Dictary.keys():

   if i == 123-45-6789:

       print(Dictary.get(i))

       break

else:

   print("Key not found")

You can further test this code by deleting Mr.Potato head's info from the dictionary. I hope this helps!

You might be interested in
Mikhail is working in an IDE and needs to test a program one step at a time to find and fix errors. What tool should he use?
FromTheMoon [43]

Answer:

c) De bug ger

Explanation:

Edge 2020

8 0
3 years ago
A device that converts analog signals into digital and vice versa for a computer to communicate over phone lines is called a ___
sweet [91]
The answer is modern
4 0
3 years ago
In this section of your final project, you will write a basic script to create and back up files. You will create this script wi
Viktor [21]

Answer:

bjdjdindbdubduf kndjnxjxjfujdjbdjbd bzjbd djbdibdu jdjdidnidndi xubdubdufjksk. xud ufbsjjdi djneibdudbdujfjfbjbdj fu. fjfjjdubdjjdbjd jdbdinkdkdnd. djjdibnfjdkndindundi jdudjbdubd djbdu bdudjdjjd djidndud dudbid anís us dj

4 0
3 years ago
Read 2 more answers
As a project manager, why is analysis an important aspect of the job? Clarify the value of teamwork List the benefits of brainst
kozerog [31]

Answer:

Analysis is an important aspect of the job because it makes proper decision making process.

The values of teamwork are to find the best solution to problems and motivate the whole team.

The benefits of brainstorming include outside input, idea building, routine breaks, .etc...

The advantages of project planning are:

  • Team members become responsible for tasks assigned to them
  • Planning is required so that labor, finance and time resources can be thoroughly considered, including the risk of project delays due to some members working on several projects at the same time
  • Allowance for contingencies should be included in project plans so that if and when they arise, risk mitigation strategies are ready.
  • With a clear direction to follow, team members don’t get sidetracked by their own ideas.

Explanation:

8 0
3 years ago
You can use the ________ method to replace an item at a specific location in an arraylist.
r-ruslan [8.4K]
The answer is the <span>ArrayList method</span>
7 0
3 years ago
Other questions:
  • Write an application that allows a user to enter any number of student quiz scores until the user enters 99. If the score entere
    15·1 answer
  • Ten 9600-bps lines are to be multiplexed using TDM. a. Ignoring overhead bits in the TDM frame, what is the total capacity requi
    6·1 answer
  • An LPN/LVN has transferred to a nursing unit and arrives for the first day. The RN checks with the LPN/LVN often throughout the
    11·1 answer
  • Charles would like to visit a specific page on the World Wide Web. How should he do it?
    10·1 answer
  • _________________ is a standard method or protocol for web pages to request special processing on the web server, such as databa
    7·1 answer
  • Write the definition of a function printLarger, which has two int parameters and returns nothing. The function prints the larger
    7·1 answer
  • write a Program which displays at least 5 different sentences that explain how technology has been used to win souls to Christ.
    6·1 answer
  • It is always safe to enter personal information into a pop-up window. true or false.
    13·1 answer
  • Plato: A university wants to install a client-server network. Which feature do you think is important for them as they set up th
    5·1 answer
  • Five Star Retro Video rents VHS tapes and DVDs to the same connoisseurs who like to buy LP record albums. The store rents new vi
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!