0

How to convert float to String in Python

Python
i = 3.1415

print(type(pi))  # float

piInString = str(pi)  # float -> str

print(type(piInString))  # str
add comment
Suggest a different solution or add another example