jvd has asked for the wisdom of the Perl Monks concerning the following question:
What's wrong ?N.Gingrich S.Thurmon R.Reagan S.Bono C.Eastwood
#!/usr/bin/perl -w @sterren=('J.v.Dijk','R.Reagan','C.Eastwood','M.Jackson','Cher','S.Bon +o'); @politici=('N.Gingrich','S.Thurmon','R.Reagan','S.Bono','C.Eastwood',' +JvDijk','M.Thatcher'); %diff=(); foreach (@sterren) {$diff{$_}=1;} @diff=grep( ! $diff{$_}, @politici); print @diff;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: array from file and compare
by talexb (Chancellor) on Dec 24, 2001 at 02:48 UTC | |
|
Re: array from file and compare
by jlongino (Parson) on Dec 24, 2001 at 00:43 UTC | |
|
Re: array from file and compare
by Fastolfe (Vicar) on Dec 24, 2001 at 03:08 UTC |