[26945] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 8909 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Feb 1 09:05:36 2006

Date: Wed, 1 Feb 2006 06:05:05 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Wed, 1 Feb 2006     Volume: 10 Number: 8909

Today's topics:
    Re: How can I remove trailing commas? (Anno Siegel)
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 1 Feb 2006 13:31:26 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: How can I remove trailing commas?
Message-Id: <drqd7e$n2v$2@mamenchi.zrz.TU-Berlin.DE>

A. Sinan Unur <1usa@llenroc.ude.invalid> wrote in comp.lang.perl.misc:
> Abigail <abigail@abigail.nl> wrote in 
> news:slrndtsb68.e1.abigail@alexandra.abigail.nl:

> >     $ perl -wle '$var = "foo,\nbar,"; $var =~ s/,$//m; print $var'
> >     foo
> >     bar,
> 
> This seals it for me. I have now been converted to the PBP recommendation 
> precisely which I can never remember what m and s modifiers do:

Here is how I keep them apart:

/s stands for "single".  It modifies the behavior of a single item,
namely ".".  /m stands for "multiple".  It modifies the behavior of
multiple (two) items, namely "^" and "$".

Anno
-- 
If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article.  Click on 
"show options" at the top of the article, then click on the 
"Reply" at the bottom of the article headers.


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc.  For subscription or unsubscription requests, send
#the single line:
#
#	subscribe perl-users
#or:
#	unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.  

NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.

#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V10 Issue 8909
***************************************


home help back first fref pref prev next nref lref last post