justaguy220
justaguy220 justaguy220
  • 02-11-2020
  • Computers and Technology
contestada

How do I add decimals in python?

Respuesta :

Cytokine
Cytokine Cytokine
  • 02-11-2020

x = 0.6

y = 0.4

print(x + y)

This will output 1.0 to the console.

You could also just do:

print(0.6+0.4)

This will yield the same result.

Answer Link

Otras preguntas

Why did it surprise people when Lorenzo Papatini danced the waltz with his dance partner in Boston? because he made close physical contact with his partner beca
y=2x+5 and y=3x-10. Solve equations
melinda bought 6 bowls for $13.20. what was the unit rate in dollars
E. coli causes diarrhea when food infected by this bacteria is consumed. However, E.coli also aids in the digestion of food. Which of the following statement ju
what does the rotation of the Earth cause?
what is the simplest form of 3/30
What are the steps to extract metal from the earths crust
What was the most influential religion in the Songhai Empire?.
solve each equation by finding all roots X^4-81=0
How long would it take 2.0x10^20 electrons to pass through a point in a conductor if the current was 10.0A?