I have been learning python lately and I wanted to write a block of code that slowly prints a string. So i came up with the code below. For some reason, it just slowly prints an empty space, it just does not print the element. I wanted to write the string on the same line so that's why i added the end=" " in the print statement. but when i remove it, the elements print fine but on individual lines. And when i remove the sleep() function, the string is printed fine. What's the issue here?
str1 = list("TEST STRING: ")
for element in str1:
print(element, end=" ")
sleep(1)