You can use pack:
use strict; use warnings; open(A,">Result.txt"); while (<DATA>){ chomp; my ($one,$two,$three) = split /\s+/; print A pack ("A10",$one); print A pack ("A7",$two); print A pack ("A8",$three); print A "\n"; } close(A); __DATA__ The Early Year Five New Swine
citromatik
In reply to Re: File Formatting - Help required
by citromatik
in thread File Formatting - Help required
by Anonymous Monk
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |