From: Ingo Weiss Date: 2006-12-07T05:17:19+09:00 Subject: Get Number of regex matches Hi, how can I get the NUMBER of matches for a regular expression in a given string? For example: for string 'Banana' and regex /a/ I should get '3' (matches) Thanks! Ingo -- Posted via http://www.ruby-forum.com/.