Completed 5-3 Alien Colors
This commit is contained in:
parent
32b6aaac86
commit
3a4c454360
16
Chapter_05/5-03_alien_colors.py
Normal file
16
Chapter_05/5-03_alien_colors.py
Normal file
@ -0,0 +1,16 @@
|
||||
# Exercise 5-3 Alien Colors
|
||||
# Learning Objective: Utilize an if statement to determine the color of an alien in a game.
|
||||
|
||||
|
||||
#passes
|
||||
alien_color = 'green'
|
||||
|
||||
if (alien_color == 'green'):
|
||||
print('Player just scored 5 points!')
|
||||
|
||||
#fails
|
||||
if (alien_color == 'yellow'):
|
||||
print('Player just scored 10 points!')
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user