+ 1
What does (str(y) mean
I'm struggling on what this piece of code means Could you explain what this code means so a 10 year old wow understand it please
1 Réponse
+ 1
str is function that converts it parameter(y) to string
Here is an example:
var = 45
notInt=str(var)
This will work:
print(notInt[1]) since string in python is array of chars
This will give a error:
print(var[1]) since it is int and not an array of digits