Re: A little bash/perl programming help?
- From: Gremnebulin <peterdjones@xxxxxxxxx>
- Date: Sat, 29 Sep 2007 09:12:53 -0700
On 27 Sep, 17:30, Ivan Marsh <anno...@xxxxxxx> wrote:
#!/usr/bin/perl
use strict;
while(<stdin>) {
chomp;
my $line = $_;
for (my $pos =0; ;$pos+=80) {
my $chunk = substr($line, $pos, 80);
if ($chunk eq '') { last; }
for (my $i=0; $i < 80; $i++) {
print $i % 10;
}
print "\n";
print $chunk;
print "\n";
}
}
.
- Prev by Date: C programming from shell
- Next by Date: [OT] on the matter of bloat
- Previous by thread: Re: A little bash/perl programming help?
- Next by thread: Re: A little bash/perl programming help?
- Index(es):