[Tutor] Trivia
Vincent Balmori
vincentbalmori at yahoo.com
Fri Jun 24 08:32:31 CEST 2011
I have to improve the trivia_challenge program so each question has a
different point value. I added a point into the text file after each
category line, so the next_block() can call it. Whenever the program
calculates the 'score = point' in main() it comes up with "TypeError:
unsupported operand type(s) for +=: 'int' and 'str' " The problem is I am
having trouble changing "point = next_line(the_file)" in the next_block() to
be an int type.
http://old.nabble.com/file/p31917610/trivia_challenge2.py
trivia_challenge2.py
http://old.nabble.com/file/p31917610/trivia.txt trivia.txt
--
View this message in context: http://old.nabble.com/Trivia-tp31917610p31917610.html
Sent from the Python - tutor mailing list archive at Nabble.com.
More information about the Tutor
mailing list