Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: push, assingn or split a file?

by ikegami (Patriarch)
on Jan 17, 2010 at 07:53 UTC ( [id://817832]=note: print w/replies, xml ) Need Help??


in reply to push, assign or split a file?

Nits:
seek( $IN1, 0, SEEK_END ); my $length = tell($IN1); seek( $IN1, 0, 0 );

can be replaced by -s.

split( /\n/, $bob );

is not equivalent. It removes the newline from each element, and it removes trailing blank lines.

Replies are listed 'Best First'.
Re^2: push, assingn or split a file?
by gam3 (Curate) on Jan 17, 2010 at 16:52 UTC
    Thanks. The -s is handy. My C is showing.

    To fix the split you need to use /^/m or just /^/ as split will know what you mean.

    -- gam3
    A picture is worth a thousand words, but takes 200K.

Log In?
Username:
Password:

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

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

    No recent polls found