I dont know much about python and am learning.
I have a variable like this,
a = 23.34853234
I want to reduce the numbers after dot. Like, i have mentioned below
a = 23.35
Please help me. Thank you
you can use round
round(a, 2)
you can read more about it here here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With