From: "冷雨" Date: 2010-10-17T09:46:47+09:00 Subject: Can't understand String#split's behavior --0016e64c3acc9846a20492c56492 Content-Type: text/plain; charset=ISO-8859-1 When I use ruby 1.8.7 I have a problem with String#split. It's fine: >>p "bAbAbAb".split(/A/) ["b", "b", "b", "b"] But it cant work: >>p "bAbAbAb".split(/(A)/) ["b", "A", "b", "A", "b", "A", "b"] I think that /A/ and /(A)/ are almost equivalent, but why can't I use /(A)/ to split string? -Lai --0016e64c3acc9846a20492c56492--