+ 2

Jungle camping

Is something wrong ? sound= input() Lion= (sound.count("Grr"))*"Lion " Tiger= (sound.count("Rawr"))*"Tiger " Snake= (sound.count("Ssss"))*"Snake " Bird= (sound.count("Chirp"))*"Bird " print (Lion + Tiger + Snake + Bird ) Failed 1 test case

5th Apr 2020, 12:26 AM
Dolani Johnson Tobi
Dolani Johnson Tobi - avatar
1 Resposta
+ 1
Assume input Snake Lion expect output is Ssss Grr but your code's output is Grr Ssss. You have to order your output depends on the input.
5th Apr 2020, 1:08 AM
你知道規則,我也是
你知道規則,我也是 - avatar