Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things

Re: Re: (zdog) Re: Finding Redundant values in arrays

by IraTarball (Monk)
on Jun 08, 2001 at 00:36 UTC ( #86739=note: print w/replies, xml ) Need Help??

in reply to Re: (zdog) Re: Finding Redundant values in arrays
in thread Finding Redundant values in arrays

This is broken, notice that it just prints the first element of the @test array? So aplaca doesn't print. In fact if you put peguin as the first element of test it prints peguin. The problem is that you're trying to be to terse. The $_ that you're using in the grep is not the $_ that aliases an element of @test, it's the $_ that aliases an element of @redundant (grep uses $_ too). So you're saying next if there's an element of redundant that matches an element of redundant. Probably not really what your were thinking of.

Update: Well, it was broken. I started getting down votes for this node, I guess 'cause it's no longer applicable.

:) Ira

"So... What do all these little arrows mean?"

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://86739]
Corion relaxes. The books for our Perl club are "done" and ready for review.

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (12)
As of 2017-11-21 16:50 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (305 votes). Check out past polls.