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
trasher [3.6K]
3 years ago
8

Label the strength of a beer based on its ABV. For each beer display the beer's name, ABV, and a textual label describing the st

rength of the beer. The label should be "Very High" for an ABV more than 10, "High" for an ABV of 6 to 10, "Average" for an ABV of 3 to 6, and "Low" for an ABV less than 3. Show the records by beer name.
Computers and Technology
1 answer:
belka [17]3 years ago
5 0

Answer:

By presuming the question expect us to write a program to address the problem and the solution code written in Python is as follow:

  1. beer_name = input("Enter beer name: ")
  2. abv = int(input("Enter ABV value: "))
  3. if(abv > 10):
  4.    label = "Very High"
  5. elif(abv >=6):
  6.    label = "High"
  7. elif(abv >=3):
  8.    label = "Average"
  9. else:
  10.    label = "Low"
  11. print("Beer Name: " + beer_name)
  12. print("ABV value: " + str(abv))
  13. print(label)

Explanation:

Firstly, we can use input function to prompt user to input beer name and ABV value (Line 1 - 2).

Next, create if else if statements to check abv fallen into which range of value and then set a label accordingly (Line 4 -11). For example if abv is 4, the label will be set to "Average".

At last, print the information of beer that includes beer name, abv value and label (Line 13 - 15).

You might be interested in
What complications are imposed if one tries to implement a dynamic list using a traditional one-dimensional array
zheka24 [161]

Answer: The expansion of the list will be required to move to a new location;

So the complications that will be imposed if one tries to implement a dynamic list using a traditional one-dimensional array is that the expansion of the list will need to move to a new location.

Explanation: When we talk about arrays,we are referring to data structures that are useful when the number of entries that are to be stored inside a list is fixed.

But for one to implement a dynamic list which always grows or shrinks at run-time arrays cannot be useful.This is because any alteration will make the entire array to be altered.

6 0
2 years ago
I need a solution for this problem asap.
madreJ [45]

Answer:

Hold on just a second I will be giving soon,

5 0
2 years ago
You are going to buy a computer, but first you want to do some research to help you select the best model for your need. Where s
Kisachek [45]
The answer to this question is c
6 0
3 years ago
Read 2 more answers
What are the challenges of photographing at night? Why did the photographer “paint” the waterfall with the flashlight?
lianna [129]
Because he needed ligh
7 0
3 years ago
Why might you use the More button in the Find and Replace dialog box?
den301095 [7]

Answer:

Use the More button to display more options to help narrow the search criteria.

Explanation:

<em> I think hope this helps you!!</em>

6 0
2 years ago
Other questions:
  • In older systems, often the user interface mainly consisted of ____-control screens that allowed a user to send commands to the
    11·1 answer
  • Why is the answer A?
    6·1 answer
  • (1 consider the following function definition: int func(int x, double y, char u, string name { //function body } which of the fo
    7·1 answer
  • ABC software company is to develop software for effective counseling for allotment of engineering seats for students with high s
    13·1 answer
  • What function would you use to find the mean in a Microsoft excel document ?
    6·2 answers
  • Samuel wanted to paste the value and the formula attached from cell B6 to cell F16. Which methods will work? Check all that appl
    5·2 answers
  • Whats a field in databases?
    5·1 answer
  • Create a basic program that accomplishes the following requirements: Allows the user to input 2 number , a starting number x and
    12·1 answer
  • Priortization is an example of a skill that helps you reach long term goals because
    14·1 answer
  • What is the simplest form of backing up data?
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!