So I'm trying to make kind of a progress bar in Python, and in a for-loop I wrote this:
print(i, end='\r', flush=True)
sleep(0.1)
so it's supposed to write 0
then 1
, etc. But instead I get something like:
0123456789101112131415161718192021222324252627282930313233343536373839
What am I doing wrong?
Update: I am using Spyder.
Here is the entire loop:
for i in range(it):
_sum += z**i * f(i)
print(i, end='\r', flush=True)
sleep(0.1)