@mhs_mhs123/

simple quiz game

Python

simple quiz

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
print('Welcome to my quiz')

begin = input('Would you like to play Y/N?')

score = 0
if begin == 'Y':
	q1 = input('What anime is the best?')
else:
	print('thanks for trying anyways')
	exit()

if q1 == 'Boku no Hero':
	print('Correct')
	score = 1
else:
	print('wrong')

if q1 == 'Boku no Hero':
	q2 = input('What color is the sky?')
else:
	print('you cannot proceed')
	exit()

if q2 == 'blue':
	print ('Correct')
	score = 2
else:
	print('wrong')


if q2 == 'blue':
	q3 = input('How old is the earth?')
else:
	print('you cannot proceed')
	exit()

if q3 == '4.5 billion years old':
	print('Correct')
	score = 3
	print('Thank you for playing my simple quiz')
	print('You got ' + str(score) ) 
	print('points')
else:
	print('wrong')