develooper Front page | perl.riscos | Postings from August 2003

Re: trailing spaces

Thread Previous | Thread Next
From:
Tom Hughes
Date:
August 20, 2003 17:36
Subject:
Re: trailing spaces
Message ID:
30a708254c.tom@loxley.compton.nu
In message <f3b4f7244c.Colin@cjfoster.iosun.co.uk>
          Colin Foster <colinj@torent.co.uk> wrote:

> Is there an easy way to remove the trailing
> spaces in the string "TRAILING SPACES     "

$string =~ s/ *$//;

Tom

-- 
Tom Hughes (tom@compton.nu)
http://www.compton.nu/


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About