[Tutor] Return cursor to beginning of line, to overprint, in DOS/windows

R. Alan Monroe R. Alan Monroe" <amonroe@columbus.rr.com
Wed Feb 19 17:56:05 2003


> R. Alan Monroe schreef op woensdag 19 februari om 05:09:28 +0000:
>> Is there a special backslash code I can use in a print statement to
>> move the cursor back to beginning of the line, to keep printing on the
>> same line over and over? I tried "\r" but that didn't work.

> Works here:
>   0 >>> print "aaa\rb"
>   baa
> What did you try exactly? Remember that 'print' prints a newline
> after the expression.

I didn't know about the newline. I fooled around with it and found
adding a trailing comma makes it work like I want, using \r. Is there
a control code for "clear to end of line"? Where's the reference for
these codes? I can't find them on Google or in the supplied docs, but
I must not be searching correctly. The \r I just happened to remember
from reading it somewhere.

Alan