develooper Front page | perl.golf | Postings from August 2002

Re: Ircnet minigolf 4, maybe too easy

Thread Previous | Thread Next
From:
Stephen Turner
Date:
August 19, 2002 01:06
Subject:
Re: Ircnet minigolf 4, maybe too easy
Message ID:
Pine.LNX.3.96.1020819090012.799A-100000@gentoo
On Sun, 18 Aug 2002, Ton Hospel wrote:

> In article <ajk1e1$tcq$1@post.home.lunix>,
> 	perl-golf@ton.iguana.be (Ton Hospel) writes:
> > Try http://www.xs4all.nl/~thospel/golf/minigolf4.html
> 
> And yet another one is finished.
> 

Looking at Ton and suo's solutions:

ton       34 @a=0..30;@a[@ARGV]=();print<@a>.$/
suo       34 @x=0..30;@x[@ARGV]=();print<@x>.$/

Can anyone explain the following? Or is it just one of those Perl quirks
that one frequently encounters when playing golf :-) ?

% perl -e'@x=(st);print <@x>'
st

% perl -e'$x="st";print <$x>'

% perl -e'%x=(st=>1);print <%x>'
%x

-- 
Stephen Turner, Cambridge, UK    http://homepage.ntlworld.com/adelie/stephen/
"This is Henman's 8th Wimbledon, and he's only lost 7 matches." BBC, 2/Jul/01


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About