in reply to Re^3: Parsing a file and finding the dependencies in it
in thread Parsing a file and finding the dependencies in it
Can anyone help to explain what this line does?
print map{" $_\n"}grep{!$seen{$_}++}priorFiles($file);
I've read the perldoc on the map function and I think the grep{!$seen{$_}++}priorFiles($file) portion extracts unique elements and the priorFiles subroutine returns the "Start" files? Could someone explain it please?
Also, I have been trying to figure out how I would be able to tell if an "ID" or "Desc" depends on another "ID" or "Desc" such as showing ID 456 depends on ID 423 which basically entails looking up the input or "Start" files to see where (which "ID") they came from
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Parsing a file and finding the dependencies in it
by Anonymous Monk on Jul 09, 2011 at 15:23 UTC | |
|
Re^5: Parsing a file and finding the dependencies in it
by Marshall (Canon) on Jul 09, 2011 at 15:10 UTC |