-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
19f1edd
commit 9e884e9
Showing
2 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# -*- coding: utf-8 -*- | ||
|
||
# Print List of Country Host of FIFA World Cup on Century 21 | ||
|
||
|
||
world_cup_21th = { | ||
'2002': ['South Korea', 'Japan'], | ||
'2006': 'Germany', | ||
'2010': 'South Africa', | ||
'2014': 'Brazil', | ||
'2018': 'Russia', | ||
} | ||
|
||
|
||
def find_country(year): | ||
if year in world_cup_21th: | ||
val = world_cup_21th[year] | ||
else: | ||
val = "NONE" | ||
|
||
return val | ||
|
||
if __name__ == '__main__': | ||
|
||
|
||
# read users input | ||
worldCupYear = raw_input("Please input FIFA World Cup year: ") | ||
|
||
# print the output | ||
print(find_country(worldCupYear)) |