Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

(ar0n: grep/splice) Re: Deleting a value in a list

by ar0n (Priest)
on Nov 29, 2001 at 21:53 UTC ( [id://128419]=note: print w/replies, xml ) Need Help??


in reply to Deleting a value in a list

And now to answer your question:
@array = grep !/$bad_ip/, @array;
But you should really should title your nodes better, since I almost wanted to answer with this:
splice @array, $index, 1;
Granted, I should've read your question before I posted :)

[ ar0n -- want job (boston) ]

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://128419]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2024-03-28 19:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found