python - 'int' Object not Callable -


I'm making a simple dragon script to process a table. I am using an array to store cell values. The code is:

  table = [] hlen = input ("Please enter the amount of the column \ n") vlen = input ("Please enter the amount of rows \ n") curcol = 1 Currow = 1 totcell = hlen * vlen while (totcell & gt; = curcol * currow): str = input ("please input" + str (curcol) + "," + str (currow)) table.append (str) if (Curl and G; = HLAN): Curo = + 1 // Process Table  

This program runs sweet, first asks cell at 1,1. All is fine, as long as the code is reloading. Heres pythons error output

  traceback (most recent call final): File "./Evacuation.py", line 13, & lt; Module & gt; Type Str = input ("Please input" + "str (curcol) +", "+ str (currow)" error: 'int' object is not worth the corner  

Any help Thank you.

You are going to hide the str created with your variable name :

you are trying call str The name is now a int

it is anything but!

In addition, you are in Python 2, so instead of raw_input instead of input


Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -