You'll have to handle $array->[$n][0] and ->[$n][1] differently, because they contain the date and text line. Considering the fact that you already know that every new ---- means it is another hour, you could discard the descriptive lines.use SuperSplit; $array = supersplit('\s+','\n','\n----\n',\*DATA');
You could print the available space from the second filesystem for every hour like this:my $str = ''; while( <DATA> ) $str .= $_ unless m|^[/-]|; } $array = supersplit('\s+','\n','\n----\n',$str);
The supersplit module can be found here.for (@$array){ print $_->[1][3]."\n"; #remember indici start at zero }
Hope this helps,
Jeroen
"We are not alone"(FZ)
In reply to Re: Getting rid of (.*) from a not-quite-complex regex.
by jeroenes
in thread Getting rid of (.*) from a not-quite-complex regex.
by deprecated
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |