On 6/15/07, HMS Surprise <[EMAIL PROTECTED]> wrote:
> I want to print a count down timer on the same line. I tried
>
>     print '\r', timeLeft,
>
> which just appends to the same line.

Sounds to me like whatever you're printing to doesn't do what you
expect when it encounters a carriage return (\r).  Is your program
running in a terminal?  Both the windows cmd.exe shell and bash under
linux seem to do the right thing when encountering a '\r'.

On the other hand, running the same code in IDLE doesn't work right,
presumably because the text window doesn't really know what to do with
a bare carriage return.

-- 
Jerry
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to