From: Joshua Ball Date: 2008-12-18T14:02:37+09:00 Subject: Re: Array problem ------=_Part_31926_17353524.1229577025829 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Arg... regex...I am new to them. ;-) You are right, of course. Thanks (for the correction and the !~) On Wed, Dec 17, 2008 at 8:57 PM, Tim Greer wrote: > Joshua Ball wrote: > > > > > Actually, the regex should have the end of string anchor: > > array.delete_if { |elem| not elem =~ /.bmp$/i } > > > > Also, remember that . is any character, whereas \. is just . for the > sake of getting exactly what you want. !~ looks cleaner to me, but > that's just personal preference in most cases. > -- > Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc. > Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers > and Custom Hosting. 24/7 support, 30 day guarantee, secure servers. > Industry's most experienced staff! -- Web Hosting With Muscle! > > ------=_Part_31926_17353524.1229577025829--