InterviewQs
Log In
Sign Up
Convert to number to float, int, and string in Python
Python
Convert to float:
i =
72
float
(i)
72.0
Convert to int:
int
(i)
72
Convert to str:
str
(i)
'72'