in reply to Re: Find common prefix from a list of strings
in thread Find common prefix from a list of strings
my @files = qw(model4run1 model2run1 model4run2 model1run1); my $same = $files[0]; $same &=$_ for @files; ($same) = split 0x00, $same,2; print "Prefix is \"$same\"\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Find common prefix from a list of strings
by Jenda (Abbot) on Jul 14, 2003 at 22:05 UTC | |
by antirice (Priest) on Jul 15, 2003 at 00:46 UTC | |
by Jenda (Abbot) on Jul 15, 2003 at 12:09 UTC | |
by fletcher_the_dog (Friar) on Jul 15, 2003 at 14:29 UTC |