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

What is the correct answer ?
Factorise fully the following A) 2x+10 B) 5x-15 C) 8x+6 D) 12x-8
How many prime numbers are there between 63 and 21
If g(x) = x4[tex]x^{2}[/tex] − x3 + x2 − x, find g(−16).
Which item would not appear on a credit report? a. Balance from your bank accounts b. Payment history on your student loans c. Balance owed on your car loan
My question is: In professional baseball, the distance to each successive base is 90 ft. If the distance from home to the pitcher’s mound is 60.5, how far is
After Gerry mows his lawn, he often puts the grass clippings into his flower garden. How will this affect his garden? It will decrease the amount of carbon in t
The perimeter of the scalene triangle is 54.6 cm. sa Which equation can be used to find the value of b if side a measures 8.7 cm?
please help 10 points!!!
What was the source of al-Qaeda’s hostility toward the West? Involvement in Middle Eastern affairs Removal of al-Qaeda’s leader from power Calling al-Qaeda a te