Discuss How to get difference of two arrays in an array in the Perl Programming forum on Dev Shed. How to get difference of two arrays in an array Perl Programming forum discussing coding in Perl, utilizing Perl modules, and other Perl-related topics. Perl, the Practical Extraction and Reporting Language, is the choice for many for parsing textual information.
Posts: 8
Time spent in forums: 51 m 51 sec
Reputation Power: 0
How to get difference of two arrays in an array
Hi All,
I am having an array A having N file names. Another array is having N-x files.I want to get an array which should have N-(N-x)= x file names. Please help.
Thanks a lot for the help in advance.
Posts: 542
Time spent in forums: 5 Days 2 h 16 m 30 sec
Reputation Power: 406
There are numerous Lists modules at the CPAN (such as Lists::Utils, etc., which can do this for you (finding unions, intersection, difference, symmetric difference, etc. between two or more lists).