EDIT: If you define a predefined type such as:
str = 5
then theoriginal functionality of that predefined will change to a new one. Lesson Learnt: Do not give variables names that are predefined or belong to special functions. List here: Here
Before you mark it as duplicate, please see this python code and results
X=5print("X value is:"+str(X))
Traceback (most recent call last):File "", line 1, in print("X value is:"+str(X))TypeError: 'str' object is not callable*
As far as I know, str should work here because I am simply printing the value of variable here. Any clues?