+ 1
Guys can you please tell me what's the wrong in this cheer creator code? I can't pass case 3!
x = int(input()) if x>10: print("High five") elif 1>x: print("shh") elif x>=1: if x<=10: print("Ra!"*x)
9 Respuestas
+ 4
x = int(input())
if x>10: # This should be >=
print("High five")
elif 1>x: # This line is not correct x<=1
print("shh")
elif x>=1: # This line is nothing
if x<=10:
print("Ra!"*x)
+ 3
Hridita Paul
x = int(input())
# 10 yards or more
if x>=10:
# error in the High five to Five
print("High Five")
# 1 yard or less
elif x<=1:
print("shh")
# from 2 yards to 9 yards
elif x<=9:
print("Ra!"*x)
+ 2
Hridita Paul There is a mistake in High five. This should be High Five.
+ 2
Yeah, I changed the "five" to "Five" and it was correct! Thank you guys!
+ 2
Hridita Paul did you try 1 on your code ? and then 4 ?
+ 2
Try entering 4 on your code it will respond as shh
+ 2
Yeah, the 4th line is not correct.
And the 6th line doesn't mean any different. It could be written anyway with only else.
Thanks anyway!!
+ 1
Brofar, sorry but what 1? I didn't understand your question.
+ 1
No. I tried to enter 4 on my code on Code Playground and it responded as Ra!Ra!Ra!Ra!