How to add a point system in python.

How do I make a point system so it adds points at each correct answer, and then I can put the total amount of points at the end?

You are viewing a single comment. View All

Somewhere near the top of your code, add this variable: points = 0
Then, everywhere you have an IF statement confirming a correct answer, add this line:
points += 1
points += 2
points += 4
or however many points you want to add to the current points total. At the end, you can print(points) to see your total. Also, you can subtract points in the same manner: points -= 2.


@Spacecraft Thank you a ton!