title: How to avoid previous printed line's shadow, while overwriting various statement using \r in perl?
body: <p>I am developing one console application using perl script. In that I am printing status of the process like "25 % Completed", "33.33 % completed" etc... In that I am using \r for printing the statement in oneline. But, while execution the previous printed statement shadow also exist, which gives confusion. How to avoid that shadow of the previous printed statement. Example code has been written below.</p>
  
  <pre><code>use strict;
  $|=1;
  
  my $length=7;
  my $progress_limit=100/$length;
   my $progress;
  for(my $i=1;$i&lt;=$length;$i++){
   $progress=$progress_limit*$i;
   print "Process completion status\: ".$progress." % Completed \r";
  
  }
  </code></pre>
  
  <p>Thanks ...</p>