Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: [perlre/perlgolf] Golf this: return -1 or return +1 on regexp subroutine please

by petral (Curate)
on Nov 07, 2002 at 18:11 UTC ( #211161=note: print w/replies, xml ) Need Help??


in reply to [perlre/perlgolf] Golf this: return -1 or return +1 on regexp subroutine please

sub by_priority { (grep$_,map-($a=~/$_/)||$b=~/$_/,qw(ORGANIZATION SERVICE FAQ))[0] or$a cmp$b }

  p
  • Comment on Re: [perlre/perlgolf] Golf this: return -1 or return +1 on regexp subroutine please
  • Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (11)
As of 2020-01-21 16:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?