Python interpreter error: unsupported operand type(s) for -: 'tuple' and 'int'
Rakesh
rakesh_usenet at yahoo.com
Tue Mar 29 20:48:15 EST 2005
To quote a much smaller trimmed-down example, here is how it looks
like:
<-->
import sys
## --------------------------------------------
## --------------------------------------------
def GenerateList():
array = ' '
for i in xrange(10):
array = (array, i)
return array
## -----------------------------------------------
# Entry Point to the whole program
## -----------------------------------------------
def main():
mylist = GenerateList()
minnumber = min(mylist)
for num in mylist:
print num - minnumber
## TODO: Interpreter errors above.
## --------------------------------
# Entry-point to the whole program
## --------------------------------
main()
<-- >
More information about the Python-list
mailing list