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

What is tan 45 degrees
624 feet to 702 feet
Please help me with this
Why do Don Quixote's friends board up his library
Which was a problem confronting president carter as the 1980 election approached?
Substance use is a negative coping mechanism to avoid?
2. You find that your stitching distance from the edge of the fabric isn't very consistent. Which attachment could you add to your machine to solve the problem?
Hunters have greatly reduced the duck population visiting and living around this wetland. We would expect to see an increase in the ___________ population as a
what are the coefficients in the polynomial 7x^2 -4x+6
Which statement comparing examples of renewable and nonrenewable resources is true? A. Solar energy is a renewable resource because it can't be used up, but