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

Plz Help!! NO LINK or REPORTED
why do the boys push a rock down from the top of the mountain lord od the flies​
help I need help asap!!
Two-Part Question: Which of the following isotopes is best suited to determining the age of a Coelophysis fossil AND does any isotope follow the relationship de
help ASAP plssss!!!!!
In which step does a mistake first occur? 8 + 2 + (3 X 3 -2) Step 1: 8 +2 + (3 x 1) Step 2: 8 +2 + 3 Step 3: 4 + 3 Step 4: 7
17. How did the Zimmerman note influence the American government's decision to enter the war on the side of the Allied forces?
Find the area of each figure.
How many moles of hydrogen are needed to react with 0.234 mol oxygen according to this equation? 2H2 + O2 -> 2H2O
Which factors caused civil unrest in the 1960s? Choose all correct answers. Black citizens were still fighting against discrimination. Americans no longer suppo