When doing numeric operation in python it always returns float. But what if i need integer . Even if the result is a whole number it returns float. Like if the result is 7 it returns 7.0. But i want integer. How can i do that. ( Is there any way to transform float into int.)
9/29/2020 1:59:46 PM
Khalid Shifullah6 Answers
New Answerhttps://code.sololearn.com/cKN5Rdk3CQqv/?ref=app Khalid Shifullah is this what u mean?
Khalid Shifullah see the same code using round () function https://code.sololearn.com/cKN5Rdk3CQqv/?ref=app
Netha_r2071 bro what if i want the output to be rounded. Like if it is 7.8 i want 8. How i do it . import math?
Sololearn Inc.
535 Mission Street, Suite 1591Send us a message