repl.it
@SakuraKimiko/

cinema simulator

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
films= {
  "Finding Nemo":[3,5],
  "Avatar":[12,10],
  "The Italian Job":[15,25],
  "Swat":[15,50]
  }
  

while True:
    choice=input("what movie do you wish to watch?:").title()

    if choice in films:
      age=int(input("How old are you?:"))

      if age >=films[choice][0]:

        num_seats=films[choice][1]
          
        if num_seats>0:
            print ("Enjoy :>")
            films[choice][1]=films[choice][1]-1
        else:
            print ("Sorry no more tickers available")

      else:
        print ("Not old enough to watch the film")
        
      
    else:
      print ("Movie not in list")