-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathuntitled.py
More file actions
46 lines (41 loc) · 943 Bytes
/
untitled.py
File metadata and controls
46 lines (41 loc) · 943 Bytes
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
# 1.
x = 5
y = 10
if 2 * x > 10:
print("Question 1 works!")
else:
print("Oooo needs some work")
# 2.
x = 5
y = 10
if len("Dog") < x:
print("Question 2 works!")
else:
print("Still missing out")
# 3.
age = 21
if age > 20:
print("You are of drinking age!")
else:
print("Argggggh! You think you can hoodwink me, matey?! You're too young to drink!")
# 4.
x = 2
y = 5
if (x ** 3 >= y) and (y ** 2 < 26):
print("GOT QUESTION 4!")
else:
print("Oh good you can count")
# 5.
height = 66
age = 16
adult_permission = True
if (height > 70) and (age >= 18):
print("Can ride all the roller coasters")
elif (height > 65) and (age >= 18):
print("Can ride moderate roller coasters")
elif (height > 60) and (age >= 18):
print("Can ride light roller coasters")
elif ((height > 50) and (age >= 18)) or ((adult_permission) and (height > 50)):
print("Can ride bumper cars")
else:
print("Stick to lazy river")