""" ------------------------------------------------- Project: Take-Away Game Standard: 91883 (AS1.7) v.1 School: Tauranga Boys' College Author: Izaak Heyder Date: THE DATE YOU COMPLETED THE CODE Python: 3.5 ------------------------------------------------- """ import random #guesses reset_guesses = 0 #Rounds rounds = 3 #user score user_score = 0 #Ai score Ai_score = 0 #round won round_won = True #Rounds round = 1 guesses = 10 title = "GUESS THE NUMBER" print(title) name = input("What is your name") print(" Hello" ,name, "welcome to GUESS THE NUMBER in this game you will guess a number between 1 and 1000 ") while round < 5: random_number = random.randint (1, 1000) print("scores", name, user_score, "comptuer", Ai_score) def round_won(): user_score = 2 while guesses > 0: guess = int(input("type your guess")) if guess == random_number : print(" you have got the correct answer" ) user_score +=1 break elif guess < random_number: print("higher") guess -=1 else: print("lower") guess-=1 round += 1