Demo entry 6783330



Submitted by Wafee on Feb 08, 2019 at 12:26
Language: Python 3. Code size: 1.2 kB.

import random
x = ""
y = ""
z = ""
total1 = 0
total2 = 0
names = 0
username = ""
username2 = ""

def main():
    display = rules
    while True:
        display = display()

def rules():
    print("The players roll two 6-sided dice each and get points depending on what they roll. There are 5 rounds in a game. In each round, each player rolls the two dice.")
    print("the rules are: ")
    print("The points rolled on each player’s dice are added to their score")
    print("If the total is an even number, an additional 10 points are added to their score")
    print("If the total is an odd number, 5 points are subtracted from their score")
    print("If they roll a double, they get to roll one extra die and get the number of points rolled added to their score")
    print("The score of a player cannot go below 0 at any point")
    print("The person with the highest score at the end of the 5 rounds wins")
    print("If both players have the same score at the end of the 5 rounds, they each roll 1 die and whoever gets the highest score wins (this repeats until someone wins)")
    return login

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).