Answers for "how to translate any data type in integer"

1

python get int from string

>>> import re
>>> string1 = "498results should get"
>>> int(re.search(r'd+', string1).group())
498
Posted by: Guest on April-07-2020
13

convert float to int python

# convert float to int 
x=3.1415
y=int(x)
print(y) #outputs 3
Posted by: Guest on December-08-2020

Code answers related to "how to translate any data type in integer"

Python Answers by Framework

Browse Popular Code Answers by Language