I want to show the progress bar in a single line. I have written the code
from tqdm import tqdm
from time import sleep
def test():
my_list = ['a', 'b', 'c', 'd', 'a', 'b', 'c', 'd', 'a', 'b', 'c', 'd']
for i in tqdm(my_list):
print(i)
sleep(.1)
I get the output as follows:
It shows the incremental progress in separate lines. Is there any way to get the progress bar to show progress in the same line as shown below?
I tried removing the print statement. Result as follows: