in reply to Perl's rank among languages
Since the number of lines is a judging criterion these 4 lines could have been written as follows:#!/usr/local/bin/perl use integer; shift; while (<>) { $tot += $_ } print "$tot\n";
Also, using integer is unnecessary and is bound to slow the code down.#!/usr/bin/perl -pl $tot += $_ }{ $_ =+ $tot
However, as arhuman points out, it looks like the contest is on hold for now.
--
John.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Perl's rank among languages
by runrig (Abbot) on Jan 03, 2002 at 00:26 UTC |