kittycarmona04 kittycarmona04
  • 03-11-2020
  • Computers and Technology
contestada

Assume: itemCost = input(“Enter cost of item: “) Write one line of code that calculates the cost of 15 items and stores the result in the variable totalCost

Respuesta :

Cytokine
Cytokine Cytokine
  • 03-11-2020

itemCost = input("Enter cost of items: ")

totalCost = 15 * float(itemCost)

print(totalCost)

The first line gets the total cost of the item from the user. The second line calculates the cost of 15 of those items and stores that value in the variable totalCost. The last line is just to test that our calculation works. I hope this helps!

Answer Link

Otras preguntas

BRAINLIESTT ASAP!!! -What Was It Like During the High and Late Middle Ages? -Are Medieval Art and Literature Important and why?
Many biologists contributed to the understanding of the structure of DNA. In the article, which five scientists did research during the 1950s that led to the cu
(4p - 5) pears and (8a + 9) apples are divided into 12 baskets equally. How many fruits are in each basket? and simplify your answer. somebody pls help
An equation for a line in the xy-plane allows you to find the value of y, given x. A.True B.False
why are electric bulbs made up of glass.
Which sentence is a scientific statement? A. Long hair looks better than short hair. B. Brick structures insulate better than wooden structures. C. Milkshak
Given that (-3,7) is on the graph of f(x), find the corresponding point for the function f(x + 5).
Look at the table marginal analysis of sweatshirt production ii. the profit at the optimal quantity of sweatshirts is:
What is the measure of xyz?
isosceles trapezoid with height c units, bases 8d units and 4d units