Gossamer Forum
Home : General : Perl Programming :

Perl Print Question

Quote Reply
Perl Print Question
Ok i'm still very new to perl and i was wondering is there a way to have a script reprint over the same line... like a progress bar? i know if i do a

$i = 0;
while ($i <= 10)
{
print "$i\n";
$i++;
}

it will generate:

1
2
3
4
5
6
7
8
9
10

So is there a way to have it keep over writing itself so i can see the numbers still counting on my output... but the final print out will only show 10?

Thanks
Subject Author Views Date
Thread Perl Print Question dipdill 7286 Mar 29, 2007, 12:28 PM
Thread Re: [dipdill] Perl Print Question
Andy 7140 Mar 30, 2007, 1:55 AM
Thread Re: [Andy] Perl Print Question
dipdill 7162 Mar 30, 2007, 6:30 AM
Post Re: [dipdill] Perl Print Question
Andy 7139 Mar 30, 2007, 7:39 AM