From: matz@... (Yukihiro Matsumoto) Date: 2002-04-26T22:46:58+09:00 Subject: Re: Return last match instead of first? HI, In message "Return last match instead of first?" on 02/04/26, "Morris, Chris" writes: |'abcdefabc' =~ 'abc' returns 0 | |How do I get it to return 6? ... finding the second abc? p "abcdefabc".rindex(/abc/) #=> 6 |Or return 9 in this case: | |'abcdefabcabc' =~ 'abc' p "abcdefabcabc".rindex(/abc/) #=> 9 matz.