Why is split: implemented in the separator rather than the string?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Why is split: implemented in the separator rather than the string?

Andy Burnett


Message: 1
Date: Thu, 19 May 2016 20:18:09 -0700
From: John Pfersich <[hidden email]>
To: Any question about pharo is welcome <[hidden email]>
Subject: Re: [Pharo-users] Why is split: implemented in the separator
        rather  than the string?
Message-ID: <[hidden email]>
Content-Type: text/plain;       charset=us-ascii

If you want to do it reversed, do it like this:

'1969-07-20' splitOn: '-'


Thanks to both of you for responding. Makes sense.

Cheers
Andy