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
STALIN [3.7K]
2 years ago
10

Write a loop that continually asks the user what food the user has in their refrigerator until the user enters apples, in which

case the loop ends. It should acknowledge the user in the following format. For the first food, the user might say "hamburger," so your response would be, "You have a hamburger with a total of 1 food(s) if they enter hamburger, and so on until they enter “apples” at which point the loop ends. ---- make sure you save your file as "may28.py" *
Computers and Technology
1 answer:
almond37 [142]2 years ago
7 0

(Disclaimer: I am not a professional, so it might not be the most concise answer possible, but I did run the Python script and it works)

Answer:

user_input = input("What food do you have in your refrigerator? ").lower()

count = 0

while True:

   if user_input != 'apples':

       count += 1

       print(f'You have a {user_input} with a total of {count} food(s)\n')

       user_input = input("What food do you have in your refrigerator? ")

   else:

       break

You might be interested in
how can you create fades with the smart tool? How can you specify the types of fade curves that are used with the smart tool?
ra1l [238]

Answer:

The correct answer to the following question is:

To create fades you can click and then drag the end of the clip with a smart tool.

Fade Dialog Box is the fade curve.  

Explanation:

Smart Tool is an application which also provide their users with the features of the quick access menu by which they can easily access their programs or the software.

By using smart tool the user also creates a crossfade.

8 0
2 years ago
What permissions are needed in order to use a work online that is in the public domain?
Maurinko [17]
<h2 /><h2>⇒Written  \: permission  \: from \\  the  \: creator</h2>

The term “public domain” refers to creative materials that are not protected by intellectual property laws such as copyright, trademark, or patent laws. ... Anyone can use a public domain work without obtaining permission, but no one can ever own it.

5 0
2 years ago
a problem exists when the current condition differs from a desired condition. This idea defines which step in problem-solving?
zhannawk [14.2K]

In algorithm the idea defines a decision box

5 0
3 years ago
Read 2 more answers
Access to sensitive or restricted information is controlled describes which of the key communications and information systems pr
Viktor [21]

Answer:

C: Security

Explanation:

Communications and information systems principles need to be, among other things, secure. They need to be able to protect sensitive information from those who intentionally not need to know. Some incident information like voice, networks, and data, are very sensitive and thus, should be secure to the right levels and should comply with privacy laws and data protection.

4 0
3 years ago
Can someone please tell me what I’m doing wrong ? Please and it’s due on Thursday!!
liberstina [14]

Answer:

Sure. In Unit test 5, it's looking for 1 instead of 0. You are returning 0 instead of 1.

0 requires 1 digit to express it and should therefore return 1.

In line 6, change the 0 to a 1.

8 0
2 years ago
Other questions:
  • What is the purpose of the “little down arrow” next to many different functions in word
    6·1 answer
  • Two electronics students are discussing static electricity and electric current. Student A says that a basic property of static
    12·1 answer
  • William found out that someone used his report on American culture without his permission. What is William a victim of?
    13·2 answers
  • Unit 3 Computer Programming Study Guide
    6·1 answer
  • Your welcome 95 points gg
    10·2 answers
  • Design the following webpage using suitable html code .
    11·2 answers
  • Select the correct answer from each drop-down menu.
    5·2 answers
  • given the variables temperature and humidity, write an expression that evaluates to true if and only if the temperature is great
    11·1 answer
  • Which of the following statements best explains how multitasking works in the human mind?
    11·1 answer
  • What are the impacts of mobile phone?as well as the positive and negative impacts?​
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!