+ 1
Useful Lists Functions task (python)
Hi! I am trying to solve the exercise in the Lists Useful Functions. But I get a test case 4 failed. And its hidden. Any ideas why? txt = input() #your code goes here if any([i == "#" for i in txt]): print (txt.replace("#", " "))
5 Respuestas
+ 2
Hi Rami!
That's because it prints nothing if there is no "#" in input variable. For that, you can add an else statement to print the input as output.
+ 5
Rami Muleys ,
please mention the exact python tutorial name, as well as the lesson number.
thanks!
+ 4
a = txt.replace("#", " ")
print(a)
+ 2
its Python Core lesson 59.2. thanks
+ 2
thank you guys