On Thu, Oct 21, 2010 at 7:25 PM, Joe Shoulak <joepshou...@yahoo.com> wrote: > I'm trying to make a sports simulation program and so far everything has > worked until I try entering: > > Score1 = (Team1Off + Team2Def)/2 > > I get the error: > > TypeError: unsupported operand type(s) for /: 'str' and 'int' > > Can someone please explain to me what this means, why it doesn't work and > what I can do to make it work?
It means that your team names are strings and that dividing strings by a number doesn't make sense. >>> ('apple' + 'orange')/2 Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: unsupported operand type(s) for /: 'str' and 'int' Geremy Condra -- http://mail.python.org/mailman/listinfo/python-list