in reply to (Golf) ranging on alphabet
# 48 * 3 = 144 chars sub GOLF { #23456789012345678901234567890123456789012345678 my$l=join'',@{+pop};my$a=pop;$l=join',',grep$l=~ s/\Q$_//g,@$a;$a={map{$$a[$_],$$a[$_+1]}0..@$a-2 };$l=~s/(.)(?:,((??{"\Q$$a{$+}"})))+/$1..$+/g;$l }
_____________________________________________________
Jeff[japhy]Pinyan:
Perl,
regex,
and perl
hacker.
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: (Golf) ranging on alphabet
by jynx (Priest) on Sep 27, 2001 at 08:46 UTC | |
by flgr (Sexton) on Sep 27, 2001 at 17:17 UTC | |
by suaveant (Parson) on Sep 27, 2001 at 17:45 UTC |