in reply to Re: Looking for a good way to split a file into equal sized arrays
in thread Looking for a good way to split a file into equal sized arrays
Im back on my way, thanks!my $infile = <STDIN>; print"Your input file is $infile\n\n"; my $outfile = "out.log"; open (INFILE, "<$infile")||die "no such file"; open (LOG, ">$outfile")||die "no such file"; while (<INFILE>) { if (/^Begin Targets/ .. /^End Targets/) { next unless /^\d/; push @data, [split /\s/]; } count++; }
|
|---|