Jon Perez <jb********@yahoo.com> writes:
I'd like to print a series of successive periods as a
progress status in a command line script using python.
Unforutnately, if I do a series of successive
print ".",
I get a space in between. Is there any way to avoid
this?
This show up regularly and might be a FAQ. The print is trying to
help you out. If you want total control, go to the lower levels:
wr=sys.stdout #redirect as desired
def myprint(txt):
wr.write(txt) #raw print
wr.flush() #flush the dots as they occur
for i in range(100):
do_something()
myprint('.')
myprint('\n')
--
ha************@boeing.com
6-6M21 BCA CompArch Design Engineering
Phone: (425) 342-0007