From: "Jesús Gabriel y Galán" Date: 2008-04-15T22:10:00+09:00 Subject: Re: Reg Exp On Tue, Apr 15, 2008 at 2:59 PM, Dipesh Batheja wrote: > Can somebody hep me with a very simple regular expression. I want to > write an regex which if matches a specific string should return false. > for example: > if i have string "Hello world", and i want to say, if you find "hello" > in this string then return false. Can someone explain how to write this? Simple approach: irb(main):007:0> a = "hello world" => "hello world" irb(main):008:0> !(a =~ /hello/) => false irb(main):009:0> !(a =~ /asdfsdf/) => true Jesus.