How to divide numbers and discard fraction in Python



269 views
How to divide numbers and discard fraction in Python
asked Nov 12, 2018 by avibootz
edited Nov 13, 2018 by avibootz

1 Answer

0 votes
a = 131
b = 4

print(a / b)
print(a // b)

print(9 / 4)
print(9 // 4)

'''
run:

32.75
32
2.25
2

'''

 



answered Nov 12, 2018 by avibootz

Related questions

2 answers 337 views
1 answer 291 views
1 answer 280 views
2 answers 247 views
1 answer 205 views
...