MLUG: Re: [MLUG] a little fun thing...
Re: [MLUG] a little fun thing...
Email address obfuscation in effect -- please click here to turn it off.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
On Wed, 6 Jul 2005, Mark Rages wrote:

Or just stick with the Python version:
python -c 'for x in range(100): print x+1,"\r",'

Neat. An old version of python (1.5) runs super slow on my Solaris box, but a newer version (2.2.3) seems to be much like perl in terms of speed. The perl doesn't mind a Ctrl-c in the middle of the run, but python gives an error message.


By the way, my use for this kind of thing is in keeping track of what's happening in a loop in a script. Use of carriage returns instead of line feeds makes it so that a single number is always being displayed and the display doesn't have to scroll.

Mike
_______________________________________________
members mailing list
EMAIL:PROTECTED
http://mlug.missouri.edu/mailman/listinfo/members