Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- perldoc perlfaq6
- perldoc perlfaq6
- perldoc perlfaq6
- while (<>) {
- chomp;
- PARSER: {
- m/ G( d+b )/gcx && do { print "number: $1n"; redo; };
- m/ G( w+ )/gcx && do { print "word: $1n"; redo; };
- m/ G( s+ )/gcx && do { print "space: $1n"; redo; };
- m/ G( [^wd]+ )/gcx && do { print "other: $1n"; redo; };
- }
- }
- regex1|regex2|regex3|...|regex15
- HAND_LINE: for ($Line)
- { /^*** ([A-Z ]+)/ and do
- { # parse the string that is captured in $1
- last HAND_LINE; };
- /^Dealt to (.+) [(.. ..)]$/ and do
- { # $1 contains the name, $2 contains the cards as string
- last HAND_LINE; };
- /(.+) folds$/ and do
- { # you get the drift
- last HAND_LINE; }; };
Add Comment
Please, Sign In to add comment