input("Press and key to proceed ") def getMoveFromId(id): if id == 1: return "Rock" elif id == 2: return "Paper" else: return "Scissors" def printMoves(p1move, p2move): print("Player 1 chose: " + getMoveFromId(p1move)) print("player 2 chose: " + getMoveFromId(p2move)) navDisplay = NavigationDisplay() print("Welcome to the Rock Paper Scissors Game!") print() rounds = getIntInput("How many rounds would you like to play? ") print() print("Player 1 moves first, make sure your opponent isn't looking.") print("Ready?") runCountdown() repeat = True while(repeat): roundCounter = 0 player1score = 0
# do not delete the code in here ############################## from helper.CsvReadWriter import CsvReadWriter from helper.TableDisplay import TableDisplay from helper.NavigationDisplay import NavigationDisplay # do not delete the code in here ############################## DATA_PATH_CSV = "data/contactList.csv" # load data csvRW = CsvReadWriter(DATA_PATH_CSV) data = csvRW.loadAsDictionary() # create display instance tableDisplay = TableDisplay(data[0].keys()) navDisplay = NavigationDisplay() # do not delete the code in here ############################## def showInvalidOrSuccess(message): print(message) input("Press any key to continue: ") while(True): tableDisplay.display(data) navDisplay.printMainMenu() userAction = input("What would you like to do? : ") userAction = int(userAction) if(userAction == 1): tableDisplay.display(data)
# do not delete the code in here ############################## from helper.CsvReadWriter import CsvReadWriter from helper.TableDisplay import TableDisplay from helper.NavigationDisplay import NavigationDisplay # do not delete the code in here ############################## DATA_PATH_CSV = "data/contactList.csv" # load data ... # create display instance tableDisplay = TableDisplay(data[0].keys()) navDisplay = NavigationDisplay() # do not delete the code in here ############################## def showInvalidOrSuccess(message): print(message) input("Press any key to continue: ") while(True): ... navDisplay.printExit()