Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: How can I completely empty out a list;

by vroom (His Eminence)
on Jan 25, 2000 at 22:08 UTC ( [id://2435]=note: print w/replies, xml ) Need Help??


in reply to How do I completely empty out an array?

You can do any of these things: assign an empty list to the array, undef it or assign -1 to its "last index value".
@array=(); undef @array; $#array = -1;

$#array = -1 was originally contrbuted by Benne -- Ed.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-04-24 04:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found