freebsd-dev/gnu/usr.bin/ptx/examples/ajay/x.pl
1994-05-06 07:54:54 +00:00

23 lines
289 B
Raku

#! /usr/local/bin/perl
while ($l = <>)
{
chop $l;
$l =~ s/\\xx //;
$l =~ s/}{/|/g;
$l =~ s/{//g;
$l =~ s/}//g;
@x = split(/\|/, $l);
printf ("\\xx ");
for ($i = 0; $i <= $#x; $i++)
{
$v = substr($x[$i], 0, 17);
$v =~ s/\\$//;
printf("{%s}", $v);
}
printf ("\n");
}