Created
October 21, 2020 16:23
-
-
Save Lycan47/0890f963005fc4e171339ac3e4ea0aa6 to your computer and use it in GitHub Desktop.
This short code challenge can help the local zoo look after its denizens.
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
camel = r""" | |
Switching on the camera in the camel habitat... | |
___.-''''-. | |
/___ @ | | |
',,,,. | _.'''''''._ | |
' | / \ | |
| \ _.-' \ | |
| '.-' '-. | |
| ', | |
| '', | |
',,-, ':; | |
',,| ;,, ,' ;; | |
! ; !'',,,',',,,,'! ; ;: | |
: ; ! ! ! ! ; ; :; | |
; ; ! ! ! ! ; ; ;, | |
; ; ! ! ! ! ; ; | |
; ; ! ! ! ! ; ; | |
;,, !,! !,! ;,; | |
/_I L_I L_I /_I | |
Look at that! Our little camel is sunbathing!""" | |
lion = r""" | |
Switching on the camera in the lion habitat... | |
,w. | |
,YWMMw ,M , | |
_.---.._ __..---._.'MMMMMw,wMWmW, | |
_.-"" ''' YP"WMMMMMMMMMb, | |
.-' __.' .' MMMMW^WMMMM; | |
_, .'.-'"; `, /` .--"" :MMM[==MWMW^; | |
,mM^" ,-'.' / ; ; / , MMMMb_wMW" @\ | |
,MM:. .'.-' .' ; `\ ; `, MMMMMMMW `"=./`-, | |
WMMm__,-'.' / _.\ F'''-+,, ;_,_.dMMMMMMMM[,_ / `=_} | |
"^MP__.-' ,-' _.--"" `-, ; \ ; ;MMMMMMMMMMW^``; __| | |
/ .' ; ; ) )`{ \ `"^W^`, \ : | |
/ .' / ( .' / Ww._ `. `" | |
/ Y, `, `-,=,_{ ; MMMP`""-, `-._.-, | |
(--, ) `,_ / `) \/"") ^" `-, -;"\: | |
The lion is roaring!""" | |
deer = r""" | |
Switching on the camera in the deer habitat... | |
/| |\ | |
`__\\ //__' | |
|| || | |
\__`\ |'__/ | |
`_\\ //_' | |
_.,:---;,._ | |
\_: :_/ | |
|@. .@| | |
| | | |
,\.-./ \ | |
;;`-' `---__________-----.-. | |
;;; \_\ | |
';;; | | |
; | ; | |
\ \ \ | / | |
\_, \ / \ |\ | |
|';| |,,,,,,,,/ \ \ \_ | |
| | | \ / | | |
\ \ | | / \ | | |
| || | | | | | | |
| || | | | | | | |
| || | | | | | | |
|_||_| |_| |_| | |
/_//_/ /_/ /_/ | |
Our 'Bambi' looks hungry. Let's go to feed it!""" | |
goose = r""" | |
Switching on the camera in the goose habitat... | |
_ | |
,-"" "". | |
,' ____ `. | |
,' ,' `. `._ | |
(`. _..--.._ ,' ,' \ \ | |
(`-.\ .-"" ""' / ( d _b | |
(`._ `-"" ,._ ( `-( \ | |
<_ ` ( <`< \ `-._\ | |
<`- (__< < : | |
(__ (_<_< ; | |
`------------------------------------------ | |
The goose is staring intently at you... Maybe it's time to change the channel?""" | |
bat = r""" | |
Switching on the camera in the bat habitat... | |
_________________ _________________ | |
~-. \ |\___/| / .-~ | |
~-. \ / o o \ / .-~ | |
> \\ W // < | |
/ /~---~\ \ | |
/_ | | _\ | |
~-. | | .-~ | |
; \ / i | |
/___ /\ /\ ___\ | |
~-. / \_/ \ .-~ | |
V V | |
This bat looks like it's doing fine.""" | |
rabbit = r""" | |
Switching on the camera in the rabbit habitat... | |
, | |
/| __ | |
/ | ,-~ / | |
Y :| // / | |
| jj /( .^ | |
>-"~"-v" | |
/ Y | |
jo o | | |
( ~T~ j | |
>._-' _./ | |
/ "~" | | |
Y _, | | |
/| ;-"~ _ l | |
/ l/ ,-"~ \ | |
\//\/ .- \ | |
Y / Y | |
l I ! | |
]\ _\ /"\ | |
(" ~----( ~ Y. ) | |
It looks like we will soon have more rabbits!""" | |
animals = [camel, lion, deer, goose, bat, rabbit] | |
# write your code here | |
while True: | |
habitat_number = input("Please enter the number of the habitat you would like to view: >") | |
if habitat_number == "exit": | |
break | |
else: | |
print(animals[int(habitat_number)]) | |
print("See you later!") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment