Write a program to enter the price and display discount percentage using ELSEIF statement. (5) If price>=5000, 20% discount If price>=3000, 15% discount If price>=2000, 10% discount If price>=1000, 5% discount

Answers

Answer 1

Answer:

Explanation:

The following code is written in Python and creates a function that takes in the price as a parameter and then returns the discount amount to the user as well as printing it to the screen.

def discountAmount(price):

   discount = 0

   if price >= 5000:

       discount = 20

   elif price >= 3000:

       discount = 15

   elif price >= 2000:

       discount = 10

   elif price >= 1000:

       discount = 5

   else:

       discount = 0

   print("Your total discount is " + str(discount) + "%")

   return discount


Related Questions

What is Coding in Computer Science?​

Answers

Answer:

Computer Science

Explanation:

computer coding is the use of computer programming languages to give computers and machines a set of instructions on what actions to perform.

Answer:

Coding is where you create games, websites, databases, and much more by typing commands to the computer.

Explanation:

The most basic coding languages include Javascript and HTML. But later, you will be able to use more advanced and difficult coding languages, such as C++ and Python. Have fun coding!

Heat transfers from an area of ____temperature to an area of ___ temperature.

Answers

Answer:

Higher, lower. I really hope this helped!!!

The Dictionary tool is helpful because it can help you:
Find spelling errors
Calculate word count
Improve word choice
Translate sentences
All of the above
Need this now!!!!!!!!!!!!

Answers

All the above is the answer.

You are volunteering to help seniors learn how to use computers. You see a lady read a suspicious e-mail. Before you can stop her, she clicks on the link in the e-mail and her screen goes blank. What just happened?

An ironically time power outage.

The link downloaded malware to her computer.

She was hit with a DDoS attack.

It was a bad link that didn't work.

Answers

I think it might be either B or D. I hope this is correct. Maybe do a guessing game lol but the one I think is mostly correct is D honesty. Sorry if I’m wrong

In the given case of malicious mail and clicking on it causing the computer to go blank is due to - The link downloaded malware to her computer.

Malware is a type of software that is designed to cause damage to computers and computer systems internally. Malware is a short version of malicious software.

It can cause by various external sources such as untrusted app, mail, dodgy link, Bluetooth connection, and others.A power outage would have lead to all computers and systems go off if not had power backup but the blank screen is not is a condition it could cause.A DDoS attack causes huge traffic to a website or server to crash.A bad link shows an error screen.

Thus, In the given case of malicious mail and clicking on it causing the computer to go blank is due to - The link downloaded malware to her computer.

Learn more about DDoS attacks:

https://brainly.com/question/10590797

Please complete the following questions. It is important that you use complete sentences and present the questions and answers when you submit your work.

1.Give several reasons why Python is such a great programming language. Explain how Python is related to flowcharts.

2.Consider this program:
Cost1 = input("Please enter the first expense: ")

Cost2 = input("Please enter the second expense: ")

print("Your total for both expenses was", Cost1 + Cost2)

3.If the user inputs “10” for the first expense and “20” for the second expense, what will the interpreter show in the final line when this program is run? If this result in not what the programmer intended, how would you explain what went wrong?

4.You are writing a line of code that should ask the user to input the balance of their bank account in dollars and cents. The program will then perform a multiplication problem to tell the user how much interest they can earn. Identify three errors in your line of input code and explain why they are incorrect. Include the corrected line of code in your answer. Here is the code:
1num = input(What is your balance?)

5.What are some kinds of comments that might be useful for a programmer to include in a program?
If you were planning how to write a program, at what point would a flowchart be helpful? At what point would pseudocode be helpful? Explain your reasoning.

Answers

Answer:

ndnxnndjdjsnnznnzbzbbdbdhdhhdbdbdbbdhdjidieiei

Explanation:

bxbzbxncnxbbcnfnnfnfndndnndndnndndnndndndnndndndndnnddnndndndnhrjjsjdudjjdjd

A line graph is a great tool for showing changes over time. Why is a line graph better than other graphs at showing this type of data?

Answers

Ans: Line graphs are used to display data or information that changes continuously over time. Line graphs allow us to see overall trends such as an increase or decrease in data over time. Bar graphs are used to compare facts. The bars provide a visual display for comparing quantities in different categories or groups.

Plz make me the brainliest

Although digital cameras today are pretty sturdy, they still require basic care and maintenance. Create a basic list of care and maintenance standards and procedures that any digital camera owner would be smart to follow. Briefly explain each item on your list.

Please help! Thank you!

Answers

Answer:

Avoid dirt and sand. Use care when cleaning dirt particles and sand from your digital camera. Do not use canned or pressurized air to clean the sand, as you might just drive the particles into the camera case. Avoid liquids. Keep all liquids away from the camera unless you own a model with a waterproof case. Avoid touching the lens and LCD. Oils from your skin smudge the lens and LCD, eventually causing permanent damage. Clean the lens and LCD with a microfiber cloth when you see a smudge from your fingertips. The lens and sun don't mix. Sunlight focused through the lens of the camera could damage the image sensor or even start a fire inside the camera. Use cleaning liquids with care. Avoid using an excessive amount of cleaning liquid with your camera. You should be able to clean the camera with a dry microfiber cloth. If a liquid is needed, place a few drops of the liquid on the cloth, rather than directly on the camera. Vacuum the bag. Dirt and sand inside your camera bag could damage your camera, so vacuum the bag regularly to keep it clean and protect your camera. Watch the temperature. Do not leave your camera in a sunny vehicle, where temperatures quickly can exceed 100 degrees Fahrenheit. Avoid leaving the camera in direct sunlight, which can damage the plastic. Finally, avoid extreme cold, too, which could damage the LCD. Use neck straps and wrist loops. If you slip while hiking, or if you lose the grip on your camera near the pool, the straps can save your camera from a potentially disastrous fall.

Explanation:

these are the exact words that I used on my assignment that I just completed I hope this helps! Enjoy your class!

The main 3 ways to care for your digital Camera  is that:

Always bag it when you are not using it. Always use lens caps to cap it.Dust it regularly.

What are the maintenance methods for the digital camera?

Know that there are ways to care for a camera. It is essential therefore to always clean at all times.

Conclusively, do use a dry and clean cloth in the wiping the physical body of the camera and note the type of cleaners or solvents that you use in the clean  up  as it needs to be a  blower, brush, etc.

Learn more about cameras from

https://brainly.com/question/26320121

Check the peripherals that are needed to see images on your computer.

Answers

The answer is monitor.
Monitor and graphics card

These are horizontal blocks of cells running across the entire width of the spreadsheet.

Answers

Answer:

Incomplete question, please submit another one.

True or False: To create a function in python, you start with the keyword "def"

Answers: True or False

Answers

Answer:

true i think

Explanation:

Answer:

true

Explanation:

i saw the other answer and wanted to contribute to your knowledge

A trackerball is a pointing device

Answers

Answer:

nice

Explanation:

When should a recurring appointment be created?

1. when an appointment has the same content, such as a dentist appointment
2.when a pattern of appointments should be created, such as a weekly appointment
3.when an appointment will take place a long time in the future, like a 10-year reunion
4.when an agenda will be revisited for an appointment, such as a meeting review

Answers

Answer:

when a pattern of appointments should be created, such as a weekly appointment

Explanation:

just did the assignment and got it right!

Answer:

B. when a pattern of appointments should be created, such as a weekly appointment

Explanation:

Check the devices that are external peripheral devices:

Answers

Answer:

Mouse, and keyboard

Explanation:

Common Sense

The first commercially available digital camera was which of the following?

Answers

Kodak Professional Digital Camera System

hope it helps

pls mark me as brainliest

Answer:

D

Explanation:

None of the above

Jude is a part of a publishing house. He does editing work for them and often comes across articles that have materials copied from some other book. Jude has to identify copied works as fair use. Which option do you think Jude will justify as fair use? A. copying 300 words from a work of 50,000 words that consists of information very important to the original book B. copying 300 words from a work of 500 words that consists of information important to the original book C. copying 300 words from a work of 50,000 words that consists of information not very important to the original book D. copying 500 words from a work of 500 words that consists of information not important to the original E. copying 500 words from a work of 500 words that consists of information very important to the original Reset Next Previous6 Next End of Semester Test: Texas Principles of Information Technology B Submit Test Reader Tools Info Save & Exit

Answers

Answer: The guy in the story did copyright

Explanation:

I am not to sure about this but this is my best guess hope it helps!!

The option that Jude will justify as fair use is copying 300 words from a work of 50,000 words that consists of information not very important to the original book. The correct option is C.

What is a publishing house?

Finding authors and their manuscripts to develop and publish as books is the primary goal of a publishing business.

Finding authors and their manuscripts to develop and publish as books is the primary goal of a publishing business. They may be in charge of numerous things, including choosing publishable manuscripts. Each sentence must be carefully examined during editing to ensure that it is well-crafted and accomplishes its intended function.

Therefore, the correct option is C. copying 300 words from a work of 50,000 words that consists of information not very important to the original book.

To learn more about publishing house, refer to the link:

https://brainly.com/question/29818093

#SPJ5

using an outline, how do you maintain your computer or cellphone​

Answers

Answer:

well first things first be good to your battery. get padded protection of your laptop.disable programs you don't use.

who is he can anyone help me​

Answers

This person is Elon Musk, the owner of Tesla :)
The person in the photo is Elon Musk. He’s the CEO of SpaceX and CEO and product architect of Tesla, Inc.,founder of The Boring Company, co-founder of Neuralink, and co-founder and initial co-chairman of OpenAI.

When you start Excel, you open a file that's called a workbook. Each new workbook comes with _____ worksheet(s), like pages in a document. You enter data into the worksheets. (Worksheets are sometimes called spreadsheets)

Question 8 options:

Ten


Two


Four


One

Answers

Answer:

one

Explanation:

Answer:

One

Explanation:

I Took The Test

Help me and i'll mark brainiest

Answers

Answer: both should be A

Explanation:

Submit your 400-word essay that analyzes and evaluates three different examples of digital media. need some help

Answers

Answer:

Essay that analyzes and evaluates three different examples of digital media is described below in complete detail.

Explanation:

The 3 Types of Digital Media

Owned MediaPaid MediaEarned MediaOwned media is what your label owns and manages. It doesn’t mean that you certainly own the program, but your corporation regulates the respective tales through which they publish their content about assistance and products.  Paid media is considered attractive, and we’re all knowledgeable of it. It includes all marketing ways that a brand spends to get viewers. Here you spend a third-party program with specs on what you want.Earned media is anything, whether content or remark, that stretches from another entity to help your brand. While most of it is optional, some expect you to contribute a substantial amount.

Other Questions
Maria decided to take her family out for dinner at a restaurant the total cost was $96.00 She decided to leave the waiter a tip of %18 of the cost of the dinner What is the total cost of the dinner including the tip without the tax Write the percent as a fraction or mixed number in simplest form.148% miss emily buys 8 ounces smoke salmon at 17.98 per pound how much money does miss emily spend on smoked salmon Which sentence would come first in chronological order?A) The Vietnam War was fought in the 1960s and 1970s.B) The Civil War was a war between the states.C) After the bombing of Pearl Harbor in 1941, the United States entered World War II.D) The colonies fought the Revolutionary War to win independence. The owner of a garden center pays $12 for each birdbath. She sells them for 55% more than she paid. Decide whether each expression represents the selling price for b birdbaths.Choose Yes or No for each expression.A.12b1 1. 55(12b) u Yesu Nob. 12(0 . 45b) u Yesu Noc.12b(1. 55)u Yesu Nod. 12(0 . 55b) u Yesu Noe. 12b(1 1 0.55)u Yesu No what about this one Which line of dialogue most clearly develops Mac's character?A. "If they can do it, you should know that you certainly can learn."B. "If I tell you, do you promise not to laugh?"C. "Well, then give me your hand and let go of the ledge."D. "Do you think you can wave with your toes and feet?" Find the equation of the line with slope 1/5 and y-intercept (0,2) Hi, please answer my Question QUICKLY!! :DFais le bon choixcrivons Fill in the blanks with cest, ilest, or elle est.1. Monique? ______ trs belle.2.______ un petit garon.3. Et M. Poiret, ______ roux?4. Comment tu trouves Mia? ______sympa, non?5. a, ______ mon cousin Jacques.6.______ trs intelligent, ton frre! Which expression is equivalent to 28+7? estimate the product by rounding each number to its greatest place value of 2342.7 times 784.3 what tends to happen to earnings as a person becomes more educated? a. earnings increase b. earnings aren't linked to education c. earnings decrease d. earnings stay the same What cultural Characteristics in the middle east are shared with with another country solve 12y^-4z^-2/6z^2y^-1 Submit your 400-word essay that analyzes and evaluates three different examples of digital media. need some help Helpppp pleaseeee well give brainlest PLS HELP ASAPdoes one plane carrying 200 people flying to Florida from Detroit for 2.5 hours actually burn up more gas than those same people all driving to Florida for 15-20 hours each using cars? Could someone help with the domain and range of these 2 graphs? According to the image above, when does Sadia experience stage 3? A) When she delivers baked goods to the townspeople. B) When she helps save her mother. C) When she leaves her house for the first time. D) When Joss comes to visit her house. solve the equation 5g + 3 =7 + 3g