Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^2: Using smartmatch with split function

by trizen (Hermit)
on May 26, 2014 at 09:18 UTC ( #1087410=note: print w/ replies, xml ) Need Help??


in reply to Re: Using smartmatch with split function
in thread Using smartmatch with split function

The smartmatch operator takes an array reference as argument:
% perl -MO=Deparse -e '1 ~~ @{[1,2]}' Smartmatch is experimental at -e line 1. 1 ~~ \@{[1, 2];}; -e syntax OK
simplifying the code to: 3 ~~ [split //, $a];

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2016-07-23 11:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (220 votes). Check out past polls.