answer.
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
Svetach [21]
1 year ago
11

The code below assigns the 5th letter of each word in food to the new list fifth. However, the code currently produces errors. I

nsert a try/except clause that will allow the code to run and produce of list of the 5th letter in each word. If the word is not long enough, it should not print anything out. Note: The pass statement is a null operation; nothing will happen when it executes.
food = ["chocolate", "chicken", "corn
fifth = []
for x in food:
fifth.append(x[4])
Computers and Technology
1 answer:
Mrrafil [7]1 year ago
6 0

Answer:

Answered below

Explanation:

foods = ["chocolate", "chicken", "corn"]

fifth_char = []

for food in foods:

"""Add a try statement to add fifth character to fifth_char list. If word is not long enough, the except part executes the the pass and nothing is printed.""'

try:

fifth_char.append(food[4])

except:

pass

#print out elements in new list

for c in fifth_char:

print(c)

You might be interested in
There are no breakpoints in the "Access Customer Account" subpage however there is an error. What will happen if you choose to s
blsea [12.9K]

Answer:

Move to the breakpoint at "Get Customer Details" stage.

Explanation:

This question is incomplete, we need a diagram and four options to resolve this questions, I attached the diagram and the options.

- The process will work all stages in the "Access Customer Account" page until the error is thrown and then focus would move to the breakpoint at "Get Customer Details" stage.

- The process will work all stages in the "Access Customer Account" page until the error is thrown and then focus would move to the "Recover1" stage.

- The process will work all stages in the "Access Customer Account" page until the error is thrown and then focus would move to the stage containing the error on the "Access Customer Account" page.

- The process will work all stages in the "Access Customer Account" page until the error is thrown and then focus would move to the "Exception1" stage.

In this case, we are going to run an extra from subpage testing in <u>Process studio</u>. Process studio is a tool where we can test these processes.

The process always it's going to work all stages in the "Access Customer Account" we're going to receive an interruption when the error is activated, moving the focus to the Get Customer Details stage.

There is an error in the stage Access Customer Account, if we run the processes with the Go button, the focus should move into the Recover1 stage, and should show the error.

But in this particular example, we must use the STEP OUT BUTTON, What means this?

The process it's going be executed, but won't show any error or message, because we have used the STEP OUT BUTTON.

If we use the STEP OUT BUTTON, the process should end but in this case, we have a breakpoint in Get Customer Details stage, for that the focus and the process will end in Get Customer Details stage and not at the end or at the Recover1 stage.

8 0
1 year ago
What kinds of unstructured data or big data might the BITS corporation want to gather in the future? What kind of devices might
charle [14.2K]

Answer:

Explanation:

There many commercial documents or formats to store like image, video, photos, audio file, web page, PDF, presentations, and we can use some tools to store this commercial data, for example, excel, microsoft access, mysql, sql, mongo db, and any tool to manage, store in our data with some structures and big data.

7 0
2 years ago
The word “computer” has become associated with anything related to screens and keyboard. However, these are not the only parts t
Digiron [165]

Explanation: The CPU is the main control chip which calculates what has to be done in order for your computer to function.

(Very interesting question you had. Hope this answer helps)

4 0
1 year ago
What does the hard disk drive do? It stores all of the information on a computer. It controls a computer’s operating system. It
umka21 [38]

The hard disk drive, OR HDD Stores all the information on the computer.

5 0
2 years ago
Read 2 more answers
An aviation tracking system maintains flight records for equipment and personnel. The system is a critical command and control s
sergeinik [125]

Answer:

offline backup solution

Explanation:

In such a scenario, the best option would be an offline backup solution. This is basically a local and offline server that holds all of the flight record data that the cloud platform has. This offline backup server would be updated frequently so that the data is always up to date. These servers would be owned by the aviation company and would be a secondary solution for the company in case that the cloud platform fails or the company cannot connect to the cloud service for whatever reason. Being offline allows the company to access the database regardless of internet connectivity.

5 0
1 year ago
Other questions:
  • Susan needs to change the color scheme in all the slides of her multimedia presentation. The presentation software program Susan
    10·2 answers
  • 9.10: Reverse ArrayWrite a function that accepts an int array and the array ’s size as arguments . The function should create a
    9·1 answer
  • Recall the problem of finding the number of inversions. As in the text, we are given a sequence of n numbers a1, . . . , an, whi
    8·1 answer
  • Two-dimensional array indexes are listed as
    8·1 answer
  • A restaurant has a case type that allows customer to book the dining room for events. Customers provide basic information includ
    11·1 answer
  • Sites like Zillow get input about house prices from a database and provide nice summaries for readers. Write a program with two
    12·1 answer
  • Ana works in the medical records department at a large medical office. Her job includes scanning and uploading medical records i
    15·1 answer
  • In this problem, we want to compare the computational performance of symmetric and asymmetric algorithms. Assume a fast public-k
    11·1 answer
  • Fill in the blanks to make the factorial function return the factorial of n. Then, print the first 10 factorials (from 0 to 9) w
    6·1 answer
  • Look at the following array definition:
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!