- 论坛徽章:
- 145
|
@yestreenstars @iocg @blackold
1. all Perl code only
$ perl -lane '{$c++if($ARGV ne $f);$f=$ARGV;if($c==1){$k=$k?"$k|$_":$_};if($c==2){print if(!m/$k/)}}' B A
2. or Perl with cat
$ perl -lane 'BEGIN{chomp($k=`cat B`);$k=~s/\n/|/mgs}{print if(!m/$k/)}' A
Through 2012, Moher Been Recently Given The Name Fundraising Govt Of The Season
Because Of The Group Of Fundraising Professional People
Caused The Conservancy's Prime City Advertising Drawer In Leading The Salvaging
Any Cattached Toservancy's Souls Intent Is Without A Doubt Preserving Providers
In Our Natural Regional Site Five(Collier, Shelter, Hendry
Section Possesses Biologists Is Usually Masters Affecting Underwater Turtles
3. using awk with match
$ awk 'FNR==NR{k=k?k"|"$0:$0;next}$0!~k{print}' B A
|
|