🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.perl
Article #52045

Re: Perl v. Python [use strict;]

#52045
From: Szymon Sokół
Date: Thu, 18 Nov 2010 20:15
27 lines
2427 bytes
On Thu, 18 Nov 2010 19:45:55 +0000 (UTC), Stachu 'Dozzie' K. wrote:

> On 2010-11-18, Szymon Sokół <szymon@bastard.operator.from.hell.pl> wrote:
[----]
>> wydajność jest drugorzędna, ale zdarzyło mi się kiedyś "optymalizować"
>> skrypt, który się wykonywał dwie godziny - zszedłem do kilku minut
>> (przepisując go całkowicie)...
> 
> Ładnie :)
> Ja kiedyś naprawiałem skrypt pisany w Perlu, który bardziej przypominał
> shella. Coś w stylu:
> #v+
> @a = `ps -A | grep costam | awk '{print \$4}'`
> $a = `ps -A | grep costam | awk '{print \$4}' | wc -l`
> for ($i = 0; $i < $a; ++$a) {
>   do_something_with($a[$i]);
> }
> #v-

O, o, o! Tam jeszcze, poza nadużywaniem ``, było dynamiczne generowanie kodu
shellowego i wykonywanie go przez system()...

-- 
Szymon Sokół (SS316-RIPE) -- Network Manager                                 B
Computer Center, AGH - University of Science and Technology, Cracow, Poland  O
http://home.agh.edu.pl/szymon/ PGP key id: RSA: 0x2ABE016B, DSS: 0xF9289982  F
Free speech includes the right not to listen, if not interested -- Heinlein  H
Technical Details
Message-ID: <sn0cuh8gtf1b.dlg@falcon.sloth.hell.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.rmf.pl!agh.edu.pl!news.agh.edu.pl!dustpuppy.sloth.hell.pl!not-for-mail
References: <c81b0b84-b5e2-4ab4-b350-73f1f5442fad@j1g2000vbl.googlegroups.com> <6rajaiomt1+ABI@leona.huge.strangled.net> <gnus.87mxp6eqme.fsf.eloy@kofeina.net> <131912bb-a04a-4fa3-a1f9-682da707349c@i17g2000vbq.googlegroups.com> <ic3qje$ac7$1@solani.org> <1vc8qyxfk5fi3$.dlg@falcon.sloth.hell.pl> <ic3vpj$osu$1@solani.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.rmf.pl!agh.edu.pl!news.agh.edu.pl!dustpuppy.sloth.hell.pl!not-for-mail
From: Szymon Sokół
 <szymon@bastard.operator.from.hell.pl>
Newsgroups: pl.comp.lang.perl
Subject: Re: Perl v. Python [use strict;]
Date: Thu, 18 Nov 2010 21:15:51 +0100
Organization: Guy Fawkes Society
Lines: 27
Sender: szymon@news.agh.edu.pl
Message-ID: <sn0cuh8gtf1b.dlg@falcon.sloth.hell.pl>
References: <c81b0b84-b5e2-4ab4-b350-73f1f5442fad@j1g2000vbl.googlegroups.com> <6rajaiomt1+ABI@leona.huge.strangled.net> <gnus.87mxp6eqme.fsf.eloy@kofeina.net> <131912bb-a04a-4fa3-a1f9-682da707349c@i17g2000vbq.googlegroups.com> <ic3qje$ac7$1@solani.org> <1vc8qyxfk5fi3$.dlg@falcon.sloth.hell.pl> <ic3vpj$osu$1@solani.org>
NNTP-Posting-Host: chello089078159131.chello.pl
Mime-Version: 1.0
X-Trace: news.agh.edu.pl 1290111401 24399 89.78.159.131 (18 Nov 2010 20:16:41 GMT)
X-Complaints-To: abuse@agh.edu.pl
NNTP-Posting-Date: Thu, 18 Nov 2010 20:16:41 +0000 (UTC)
User-Agent: 40tude_Dialog/2.0.15.1 Hamster/2.1.0.11
X-Face: xic?6f"rD)k-tM.]L]A6l4W7_aGt({}&{D,hiRI.8cPtf,1F.w@Qkl!vr23o1UY-BfXO$p< hk5>ijB?eBy)?!C<@)+%U\&`1X)MJ>.i.qgkY]4mvL62j<|xJRG/5:7:l8q]x;v!)Bz^r/!yG8DxoD -@fnC,g]BAXj
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit