Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Regex: Char-class equivalent for [^]

by BrowserUk (Pope)
on Jan 14, 2013 at 14:01 UTC ( #1013216=note: print w/replies, xml ) Need Help??


in reply to Regex: Char-class equivalent for [^]

How about one of these?

"the quick brown fox\njumps over the lazy dog" =~ m[([\W\w]+)] and pri +nt $1;; the quick brown fox jumps over the lazy dog "the quick brown fox\njumps over the lazy dog" =~ m[([\S\s]+)] and pri +nt $1;; the quick brown fox jumps over the lazy dog "the quick brown fox\njumps over the lazy dog" =~ m[([\D\d]+)] and pri +nt $1;; the quick brown fox jumps over the lazy dog

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

Replies are listed 'Best First'.
Re^2: Regex: Char-class equivalent for [^]
by LanX (Chancellor) on Jan 14, 2013 at 14:08 UTC
    Hmm, bundling complementary char-classes is a clever idea!

    thx! :)

    Cheers Rolf

    UPDATE: and works equally in both languages!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1013216]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (9)
As of 2016-12-05 19:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (91 votes). Check out past polls.