Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use strict;
- use warnings;
- my $file = shift;
- my $datas = [];
- open my $fh, '<', $file
- or die "Cannot open '$file': $!";
- while (my $line = <$fh>) {
- chomp $line;
- my @record = split /,/, $line;
- push @$datas, \@record;
- }
- close $fh;
- 1;
Add Comment
Please, Sign In to add comment