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

A milk carton can hold 3.78 liters of milk. Each morning, a dairy farm ships cartons of milk to a local grocery store. The cost

of producing one liter of milk and the profit of each carton of milk vary from farm to farm. Write a program that prompts the user to enter: The total amount of milk produced in the morning. The cost of producing one liter of milk. The profit on each carton of milk. The program then outputs: The number of milk cartons needed to hold milk. Round your answer to the nearest integer. The cost of producing milk. The profit for producing milk.
Computers and Technology
1 answer:
makvit [3.9K]3 years ago
3 0

Answer:

milk_produced = float(input("Enter the total amount of milk produced in the morning: "))

liter_cost = float(input("Enter the cost of producing one liter of milk: "))

carton_profit = float(input("Enter the profit on each carton of milk: "))

carton_needed = round(milk_produced / 3.78)

cost = milk_produced * liter_cost

profit = carton_profit * carton_needed

print("The number of milk cartons needed to hold milk is " + str(carton_needed))

print("The cost of producing milk is " + str(cost))

print("The profit for producing milk is " + str(profit))

Explanation:

*The code is in Python.

Ask the user to enter milk_produced, liter_cost and carton_profit

Calculate the number of milk cartons needed, divide the milk_produced by the capacity (3.78) of a cartoon and round the result

Calculate the cost, multiply the milk_produced by liter_cost

Calculate the profit, multiply the carton_profit by carton_needed

Print the results

You might be interested in
2.
Sauron [17]
Im pretty sure it is b
7 0
3 years ago
Https://meetme.bit.nl/OfficialTrapstarz Join yall its my birthday
laila [671]

Answer:

HAPPY BIRTHDAY EVEN THO WE JUST MET

5 0
3 years ago
Read 2 more answers
Start with the following Python code.
Reil [10]

Answer:

huwugsgssuaihsux h baiThatha svaadishht us

7 0
3 years ago
Sara is having a tough time finding the cause of a problem on a computer she is troubleshooting. She found a possible problem bu
sp2606 [1]

<u>I will advise Sara to do research about the problem on the Internet.</u>

<u>Explanation</u>:

Internet is a network that helps in connecting one computer with other globally. Communication between the computers is possible until the computers are connected with to the Internet. Internet helps in getting information from any computer and interacts with the users of the computer.

Sara finds some issue with her computer. She was troubleshooting, but she could not find the exact problem. She was not sure with the problem that she found. It is better for Sara to do research about her problem on Internet and find the solution.

7 0
3 years ago
Someone help me to create book-r-us database design with logical and physical diagram
icang [17]
Hey men, i recommend, not saying that here, do that with a friend or someone but no here aight? <span />
6 0
3 years ago
Other questions:
  • What is the difference between a denial-of-service attack and a distributed denial-of-service attacks? which is potentially more
    10·1 answer
  • What do you think of explaining to young people, from high school, the legitimacy of copyright and the dangers they can run on t
    11·1 answer
  • Which references are updated when you copy the formula =$E6-MAX(H$1:J4)
    10·1 answer
  • Which of the following statements about light-emitting diodes is correct
    11·1 answer
  • All of the following methods ensure the stored data are unreadable except…?
    7·1 answer
  • List the five body functions that monitor homeostasis.
    7·1 answer
  • Many contemporary languages allow two kinds of comments: one in which delimiters are used on both ends (multiple-line comments),
    7·1 answer
  • What was Bill Gates purpose for starting a business?
    12·1 answer
  • Who knows songs that are sad,happy,excited, and calm
    10·1 answer
  • How do i delete peoples comments
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!