+ 1

What is floats?

19th May 2017, 3:37 PM
Faizan Faheem
Faizan Faheem - avatar
7 Respuestas
+ 7
Numbers with decimals. As opposed to Integers which are whole numbers. Examples of Floats = -0.1, 5432.006, 3.33333 Examples of Integers = 0, 899, -52 Division of an Integer will always result in a Float.
19th May 2017, 4:48 PM
Leigh E. O.
Leigh E. O. - avatar
+ 3
floats are numbers with decimals. used for differenciating from integers, which are whole numbers.
19th May 2017, 3:39 PM
droste
droste - avatar
+ 1
Thanks.
19th May 2017, 3:47 PM
Faizan Faheem
Faizan Faheem - avatar
+ 1
when we use floats in the program the result will be in decimal form where as when we use integer we will get output in exact value without decimals
19th May 2017, 5:20 PM
Anantha
Anantha - avatar
+ 1
so python treats integers and decimals differently being that in decimal form python cannot accurately define to the smallest point, essentially because mathematically speaking, we can divide to smaller divisions infinitely... is this correct? so there is only one value that can be completely accurate, any integer?
19th May 2017, 5:42 PM
Imagined Self
Imagined Self - avatar
+ 1
when we use floats then the output will be in decimal value
19th May 2017, 5:43 PM
Anantha
Anantha - avatar
+ 1
ya when we use integer we will get Tha exact Value
19th May 2017, 5:45 PM
Anantha
Anantha - avatar