in reply to Code explanation needed (was: What does this mean)
Loops through an array "file" pulling out array indexes which start with the string "$storeline|" (whatever storeline is) and set @matches to the result. This could be written as,my @matches = grep { $file[$_] =~ /^\Q$storeline|\E/ } 0..$#file;
Calls the subroutine no_match passing $storeline as the arguement. returns if @matches is empty.@matches = grep { /^\Q$storeline|\E/ } @file;
Calls the subroutine duped_ids passing $storeline as the arguement. returns if the number of elements in @matches is greater than 1.no_match($storeline), return unless @matches;
</CODE>duped_ids($storeline), return if @matches > 1;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: What does this mean
by Abigail-II (Bishop) on Jun 10, 2002 at 13:45 UTC | |
by tadman (Prior) on Jun 10, 2002 at 14:08 UTC | |
by Abigail-II (Bishop) on Jun 10, 2002 at 14:18 UTC | |
by tadman (Prior) on Jun 10, 2002 at 14:32 UTC | |
by Abigail-II (Bishop) on Jun 10, 2002 at 14:49 UTC | |
| |
by Sifmole (Chaplain) on Jun 10, 2002 at 13:54 UTC |