SPUG: regular expressions

Menton, Stephen stephen.menton at cingular.com
Tue Jan 17 13:37:56 PST 2006

I'd opt for 's/(\w+)/\u$1/g' if you want to leave the remaining
characters untouched, 's/(\w+)/\u\L$1/g' if you want to force all other
letters to be lowercase.


-----Original Message-----
From: spug-list-bounces at pm.org [mailto:spug-list-bounces at pm.org] On
Behalf Of luis medrano
Sent: Tuesday, January 17, 2006 13:19
To: spug-list at pm.org
Subject: SPUG: regular expressions


I have a problem I need to modified some strings with the first
character of each word with a upper case for example:


perl is number one


Perl Is Number One

my question is how can I do this using regular expressions?

Luis _____________________________________________________________
Seattle Perl Users Group Mailing List  
     POST TO: spug-list at pm.org
SUBSCRIPTION: http://mail.pm.org/mailman/listinfo/spug-list
    MEETINGS: 3rd Tuesdays
    WEB PAGE: http://seattleperl.org/

More information about the spug-list mailing list