@ReubenBakas/

Homework

Python

No description

fork
loading
Files
  • main.py
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import random

name1=input("\nWhat is your first name for the game ?: ")
name2=input("And your second name please(see i am being nice and polite look at me go).")
N1=name1.upper()[0]
N2=name2.upper()[0]
N22=name2.upper()[-1]
print("okay, (i dought you put in your real name but anyhow) Hello this is your nickname ",N1,N2,N22,sep=(""))

#Start of Random Number Game

print("\nThe Random Number Game has now started for every number you get right you get one Krabby Pattie which was a word picked by a different AI")
negscore=0
KrabbyPatties = (0)
agian="yes"
while agian=="yes" and negscore==0:
# 0 to 9 number picked
  if KrabbyPatties<2:
    randomnum=random.randint(0,9)
    guess=int(input("\nWhat is your guess for a random number that will be picked by an AI form 0 to 9?: "))
    #Random numbers
    if guess==randomnum:
      KrabbyPatties+=1
      print("\nCorrect your Krabby Patties is now",KrabbyPatties)
      if KrabbyPatties==2:
        print("\nThe random numbers is now going to be picked up to 15")
      agian=input("\nDo you want to play agian?:")
    else:
      print("\nWrong you got",KrabbyPatties,"Krabby Patties in total")
      print("it wasnt",guess,"it was",randomnum)
      negscore+=1
  # 0 to 15 number picked
  elif KrabbyPatties>=2:
    randomnum2=random.randint(0,15)
    guess2=int(input("\nWhat is your guess for a random number from 0 to 15?!: "))
    if guess2==randomnum2:
      KrabbyPatties+=1
      print("\ncorrect your Krabby Patties is now",KrabbyPatties)
      if KrabbyPatties==4:
        KrabbyPatties+=2
        print("\nYou get 2 extra points now!! this means your totalscore is",KrabbyPatties,"")
      agian=input("\nDo you want to go agian?: ")
    else:
      negscore=+1
      print("\nThat is incorrect you got",KrabbyPatties,"Krabby Patties in total")
      print("it wasnt",guess,"it was",randomnum2)