Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: UPDATE: Variable number of words/fields in a line/record

by jeroenes (Priest)
on Jun 18, 2001 at 10:58 UTC ( [id://89237]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    while( <> ){
      split;
      splice @_, 0, 2; #removes first two elements
      store_elements_function( @_ ); #sub to store the remainder
    }
    
  2. or download this
    my @std_keys = qw/proto .../;
    my @ext_keys = qw/name9 name10 name11/;
    ...
      print "My proto is: ",$hash{'proto'},"\n";
    
    ...
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (5)
As of 2024-06-23 13:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.