|
|
 |
|
Title: test
Submitter: test test
(other recipes)
Last Updated: 2002/09/24
Version no: 1.0
Category:
Web Services
|
|
10 vote(s)
|
|
|
|
Description:
test
Usage: Text Source
my @fruits = ("apples", "pears", "oranges");
foreach (@fruits) {
if ($_ ne "apples") {
print "I like $_\n";
}
}
The license for this recipe is available here.
Discussion:
test
|
|
Add comment
|
|
Number of comments: 3
Or, as a one liner ..., Grant McLean, 2002/10/10
print "I like $_\n" foreach grep $_ ne 'apples', @fruits;
Add comment
Had to vote it down..., T.Rob Wyatt,T.Rob Wyatt, 2002/11/14
It was taking up the top spot in the "Highest rated recipes" section.
Add comment
Or, as another one-liner ... =), Gabriel Knoy, 2003/06/06
map { print "I like $_\n" unless /^apples$/; } ("apples", "pears", "oranges");
Add comment
|
|
|
|
|
 |
|