Won't someone please care for them? The pentuplets appeared on my doorstep. They all do the same thing. Can you figure it out? I could tell you, but where's the fun in that?
# 57*3 = 171
sub emb1 {
$_[0]=~/^(?{[("")x2]})(.*)(?{[$^R->[0].$1,$^R->[1]]})(?:(
.)(?{[$^R->[0],$^R->[1].$2]})(.*)(?{[$^R->[0].$3,$^R->[1]
]}))*\z(?(?{$^R->[0]eq$_[1]})(?{$_[2]=$^R->[1]})|(?!))/sx
}
# 54*3 = 162
sub emb2 {
our$i=\$_[2];@_=@_;my$R;$R=qr/(?{substr$_[1],0,1,''})(
(??{''ne$^R&&"[^\Q$^R\E]*\Q$^R"}))(?{chop($$i.=$1)if$1
ne'';$^R})(??{''ne$^R&&$R})(?{$$i.=$'})/x;$_[0]=~/^$R/
}
# 52*3 = 156
sub emb3 {
@_=(@_,our$i=\$_[2]);$_[0]=~m{^(?(?{${$^R=\substr$_[
1],0,1}ne''})((??{"[^\Q${$^R}\E]*\Q${$^R}"}))(?{chop
(${$^R},$$i.=$1)}))+(?(?{$_[1]ne''})^)}&&($$i.=$',1)
}
# 49*3 = 147
sub emb4 {
use re"eval";$_[0]=~m{^@{[map+qr{(?>([^$_]*)$_(?{
$_[$^F].=substr($_[$%],$-[-1],$+[$#-]-$-[-1])}))}
,map+quotemeta(),split//,$_[1]]}}x&&($_[2].=$',1)
}
# 41*3 = 123
sub emb5 {
$_[0]=~m{^@{[map"([^\Q$_\E]*)\Q$_",split/
/x,$_[1]]}}x&&($_[2]=join('',map(substr($
_[0],$-[$_],$+[$_]-$-[$_]),1..$#-),$'),1)
}
_____________________________________________________
Jeff
[japhy]Pinyan:
Perl,
regex,
and
perl
hacker, who'd like a
job (NYC-area)
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;