in reply to Code not showing properly
You're incrementing $i three times in the line with the split. That makes for many holes in your three arrays. Perhaps a push would be easier. It's a bit longer, though -- I might keep an array of hashes instead.
while (<FILE>) { chomp; my ($file, $name, $keyword) = split /:/, $_; push @File, $file; push @Name, $name; push @Keywords, $keyword; }
|
|---|