From: Geometric Patterns Date: 2010-11-14T04:06:57+09:00 Subject: Very simple regex question Hi, I have a very simple regex question. I don't understand why the regex in the example below isn't identifying that the string is longer than 12 characters long... >> line = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxx" => "xxxxxxxxxxxxxxxxxxxxxxxxxxxxx" >> if line =~ /[a-zA-Z]{2,12}/ >> puts "good" >> else ?> puts "bad" >> end good => nil >> Any ideas? Many thanks in advance! -- Posted via http://www.ruby-forum.com/.