Error str not callable

77 Views Asked by At

Here is a sample of code (python 3.6):

n = 2
x = 2**n
Q = str(x)
print(q)

This yields an error "str object is not callable". But I didn't understand why? I am working with much larger numbers (integers), and I need to convert them to a string before I can work with them. How can I do that?

0

There are 0 best solutions below