-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp01.py
More file actions
122 lines (99 loc) · 2.41 KB
/
app01.py
File metadata and controls
122 lines (99 loc) · 2.41 KB
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
print("Title of program: MCQ revision program")
print()
counter = 0
score = 0
total_num_of_qn = 3
counter +=1
tracker = 0
while tracker !=1:
print("Q"+str(counter)+") "+ "What is 100÷2(16+9)+613-614+1230?")
print(" a) 1240")
print(" b) 1232")
print(" c) 1233")
print(" d) 1128")
answer = input("Your answer: ")
answer = answer.lower()
if answer == "a":
output = "You're wrong"
score -=1
elif answer == "b":
output = "Try again"
score -=1
elif answer == "c":
output = "Congratulations"
tracker =1
score +=1
elif answer == "d":
output = "Use your calculator"
score -=1
else:
output = "Please choose a, b, c or d only."
print()
print(output)
print()
print("Your current score: " + str(round((score/total_num_of_qn*100),1)) + "%" )
print()
print()
counter +=1
tracker = 0
while tracker !=1:
print("Q"+str(counter)+") "+ "How many atoms are there in the chemical formula C169,719H270,466N45,688O52,238S911")
print(" a) 539022")
print(" b) 236843")
print(" c) 539023")
print(" d) 432683")
answer = input("Your answer: ")
answer = answer.lower()
if answer == "a":
output = "yes congratulations you have passed your mathematics and eyesight test"
tracker =1
score +=1
elif answer == "b":
output = "nope"
score -=1
elif answer == "c":
output = "sorry nope"
score -=1
elif answer == "d":
output = "check again"
score -=1
else:
output = "Please choose a, b, c or d only."
print()
print(output)
print()
print("Your current score: " + str(round((score/total_num_of_qn*100),1)) + "%" )
print()
print()
counter +=1
tracker = 0
while tracker !=1:
print("Q"+str(counter)+") "+ "How many elements are there in Zn(NO3)2?")
print(" a) 4")
print(" b) 7")
print(" c) 2")
print(" d) 3")
answer = input("Your answer: ")
answer = answer.lower()
if answer == "a":
output = "count again carefully"
score -=1
elif answer == "b":
output = "element or atom"
score -=1
elif answer == "c":
output = "check"
score -=1
elif answer == "d":
output = "congratulations"
tracker =1
score +=1
else:
output = "Please choose a, b, c or d only."
print()
print(output.lower())
print()
print("Your current score: " + str(round((score/total_num_of_qn*100),1)) + "%" )
print()
print()
print("End of quiz!")