Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: question on perl's split function

by Prof Vince (Friar)
on Oct 22, 2007 at 10:00 UTC ( #646410=note: print w/ replies, xml ) Need Help??


in reply to question on perl's split function

You can also use a regexp :

my @arr = $string =~ m,([^/]+),g;

Please note that Perl's split isn't PHP's and expects a pattern (or ' ') as its first argument, so you'd better not split on a string if you don't know what's happening there.


Comment on Re: question on perl's split function
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2015-08-30 10:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The oldest computer book still on my shelves (or on my digital media) is ...













    Results (348 votes), past polls