From: Phrogz Date: 2007-09-28T02:15:03+09:00 Subject: Re: Break apart a string by kind of characters On Sep 27, 9:55 am, Daniel Waite wrote: > Hi all, I've an interesting problem. Imagine the following string: > > 'a1000aa' > > I want to break it apart like so: > > [ 'a', '1000', 'aa' ] irb(main):001:0> s = 'a1000aa' => "a1000aa" irb(main):002:0> s.split( /(\d+)/ ) => ["a", "1000", "aa"]