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

Re: Re: Tutorial suggestion: split and join

by zby (Vicar)
on Aug 29, 2003 at 07:47 UTC ( [id://287607]=note: print w/replies, xml ) Need Help??


in reply to Re: Tutorial suggestion: split and join
in thread Tutorial suggestion: split and join

The converse to split is the join function, which takes a list of strings and joins them together again.

No. The converse to a split is a regular expression (with matching). The idea here is that with matching you specify what you want to match and you get that as a return value ala @simpsons = "Bart Lisa Maggie Marge Homer" =~ /(\w+)/g). With split you specify all the things you don't want and you get everything else. Which one you use depends on what is more natural to specify.

I don't understand what meaning of converse you use here. English is not my first language - but here is what I found for 'converse' in the Meriam-Webster online dictionary:
something reversed in order, relation, or action: as a : a theorem formed by interchanging the hypothesis and conclusion of a given theorem b : a proposition obtained by interchange of the subject and predicate of a given proposition <"no P is S " is the converse of "no S is P ">
I believe the OP used 'converse' as a synonim for 'inverse' in the mathematical sense, i.e. he wanted to say that  split o join = identity. Which is quite close to being correct.

Or perhaps you meant join in the first sentence? This possibillity occured to me just after posting this comment.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2024-04-25 16:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found