0

3/4 is given 0 in my case

3rd Feb 2017, 1:47 PM
BE THE BOSS
BE THE BOSS - avatar
4 Answers
+ 3
It is because 4 fits 0 times in 3. Next time post your code. you should use float variables to get float answer: 3.0 / 4.0
3rd Feb 2017, 1:49 PM
Ladislav Milunović
Ladislav Milunović - avatar
+ 1
int / int gives an integer output not a float
3rd Feb 2017, 1:49 PM
Abhishek Genva
Abhishek Genva - avatar
+ 1
Everyone saying it's normal: you are using Python2, trying using Python3 instead
3rd Feb 2017, 7:25 PM
Amaras A
Amaras A - avatar
0
It is because of the two value type are integer
3rd Feb 2017, 2:00 PM
Karoy
Karoy - avatar