Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Best way to print variables in regex

by Kenosis (Priest)
on Jan 20, 2014 at 23:22 UTC ( [id://1071393]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    
    $tags{ uc $1 }++ while $tagged =~ m!<([^/]+?)>!g;
    print "$_: $tags{$_}\n" for sort keys %tags;
    
  2. or download this
    <det>the</det> <jj>quick</jj> <jj>brown</jj> <nn>fox</nn> <vbd>jumped<
    +/vbd> <in>over</in> <det>the</det> <jj>lazy</jj> <nn>dog</nn>
    
    ...
    JJ: 3
    NN: 2
    VBD: 1
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1071393]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2024-04-19 03:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found