develooper Front page | perl.beginners | Postings from August 2009

Re: Code for making the 'clock'

Thread Previous
Shawn H. Corey
August 19, 2009 08:27
Re: Code for making the 'clock'
Message ID:
Tony Esposito wrote:
> Anyone have the code that make the 'clock' show when a Perl program is running?
> What I mean by the 'clock' is the command-line movement that sequentially does the following (in place):
> - \ | / - \ | / 
> when running it looks like a 'clock' to show the user that something is processing ...
> Thx.

Use the backspace '\\b' to back up and over-print the characters.  See 
`perldoc perlop` under "Quote and Quote-like Operators" and search for /\\b/

Also see `perldoc -f sleep` to slow it down. :)

Just my 0.00000002 million dollars worth,

Programming is as much about organization and communication
as it is about coding.

I like Perl; it's the only language where you can bless your

Thread Previous Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About