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

if a cross between two pea plants results in F1 results of 155 tall peas and 45 short peas what were the genotypes of the parents
Suppose z varies directly with y and directly with the cube of x. If z=216 when x=2 and y=9 , what is z when x=7 and y=5 ?
i need help with the questions that u have highlighted please help.
\large{\dfrac{2}{7} \div 6 =}
HELP PLSSS i dont understand
By 1850, 55 percent of the slaves in the South were being forced to grow which cash crop?
For mortgages entered into after December 15, 2017, the amount of interest the taxpayer can deduct is no more than ______________ of the debt used to buy, build
Find the numerical values of the following expressions. 4 a 8 − a if a = − 2
An experiment consists of four outcomes with P (E1) = 0.2, P (E2) = 0.3, and P (E3) = 0.4. The probability of P (E4) is: a. 0.50 b. 0.90 c. 0.02 d. 0.10 e. none
the products in ? are the ? needed for cellular respiration.​