Jos Backus <josb / cncdsl.com> writes:

> > > to do this. But I'm looking for a replacement in the succinct
> > >
> > >     ($ext) = $mbox =~ /.*?-(.+)$/;
> > >     ($ext2) = $ext =~ /.*?-(.+)$/;

How about

   ext, ext2 = /-(.*?-(.*))/.match(mbox).to_a[1,2]

That's fairly succinct  :)



Dave