From: Charles A Gray Date: 2006-12-29T00:23:47+09:00 Subject: Re: Strip is not stripping trailing whitespace On Thu, 2006-12-28 at 17:52 +0900, Eric Hodel wrote: > > This is why I shouldn't code at 3:30am! I had used chop instead, > > which > > of course truncated the text in rare cases. How can I remove \240? > > String#gsub > > line.gsub(/[\240]/, '') > > line.chop will remove one of the "\240"s. line.chop.chop.chop will remove all three, but they will still be on line. To completely remove them, use line.chop!.chop!.chop! where line = the string you wish to change.