------ art_59514_23360965.1168213063262 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline On 1/7/07, Daniel Finnie <danfinnie / optonline.net> wrote: > # Find words that use the same letters > selectedWords ict.scan(/^[#{baseWord}]{3,6}$/) I was really impressed when I first saw this. It doesn't quite work if you want to exclude reusing the same letter more than once ("hhh".scan(/^[hello]{3,6}$/) ["hhh"]) but it comes so close to something I've only ever thought about implementing as a recursive method. Unfortunately I don't know much about this but now I wonder if it's possible to find all partial permutations of a word with a regexp. ------ art_59514_23360965.1168213063262--