[18739] in Perl-Users-Digest
Perl-Users Digest, Issue: 907 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue May 15 14:15:44 2001
Date: Tue, 15 May 2001 11:15:25 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <989950525-v10-i907@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Tue, 15 May 2001 Volume: 10 Number: 907
Today's topics:
static values in a subroutine <Travis.Stevens@noaa.gov>
Re: static values in a subroutine (Anno Siegel)
Re: static values in a subroutine (M.J.T. Guy)
Re: static values in a subroutine (Anno Siegel)
Re: static values in a subroutine <bart.lateur@skynet.be>
Re: static values in a subroutine (Craig Berry)
Stumped on $?, duplicate output <djberge@uswest.com>
Re: URGENT: CGI program wanted! <gtoomey@usa.net>
Re: URGENT: CGI program wanted! <uri@sysarch.com>
Re: use an expanding set of modules (Anno Siegel)
Re: use an expanding set of modules (Dave Murray-Rust)
Re: use an expanding set of modules (Anno Siegel)
Re: use an expanding set of modules <uri@sysarch.com>
Re: use an expanding set of modules (Anno Siegel)
Re: What is wrong with my Regular Expression? (Randal L. Schwartz)
Re: What is wrong with my Regular Expression? <godzilla@stomp.stomp.tokyo>
Re: What is wrong with my Regular Expression? <godzilla@stomp.stomp.tokyo>
Re: What is wrong with my Regular Expression? (Randal L. Schwartz)
Re: What is wrong with my Regular Expression? (Eric Bohlman)
Re: What is wrong with my Regular Expression? <godzilla@stomp.stomp.tokyo>
Re: Worldclock program??? (Steve)
Re: Worldclock program??? <godzilla@stomp.stomp.tokyo>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 15 May 2001 10:06:09 -0600
From: Travis Stevens <Travis.Stevens@noaa.gov>
Subject: static values in a subroutine
Message-Id: <3B0153F0.74289C0F@noaa.gov>
Hello and good (morning).
I've been searching through my Programming Perl book and my Learning
Perl book and have not found any information on this subject.
Basically, I have a subroutine where I want to keep some values around
so the next time I call the subroutine the values can be used. IE
static varibles in C.
any help would be appreciated.
-Trav
------------------------------
Date: 15 May 2001 16:22:07 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: static values in a subroutine
Message-Id: <9drl3f$ceu$4@mamenchi.zrz.TU-Berlin.DE>
According to Travis Stevens <Travis.Stevens@noaa.gov>:
> Hello and good (morning).
>
> I've been searching through my Programming Perl book and my Learning
> Perl book and have not found any information on this subject.
> Basically, I have a subroutine where I want to keep some values around
> so the next time I call the subroutine the values can be used. IE
> static varibles in C.
Just use your usual (lexical) variables in a scope that can be seen
when the sub is compiled:
{
my $static;
sub foo {
$static = shift if @_;
print "$static\n";
}
foo( 'a');
foo;
foo( 'b');
foo;
}
The bare block isolates the sub's private variables from the rest
of the program, but isn't strictly necessary.
Anno
------------------------------
Date: 15 May 2001 16:36:03 GMT
From: mjtg@cus.cam.ac.uk (M.J.T. Guy)
Subject: Re: static values in a subroutine
Message-Id: <9drltj$f1v$1@pegasus.csx.cam.ac.uk>
In article <9drl3f$ceu$4@mamenchi.zrz.TU-Berlin.DE>,
Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> wrote:
>
>Just use your usual (lexical) variables in a scope that can be seen
>when the sub is compiled:
>
> {
> my $static;
>
> sub foo {
> $static = shift if @_;
> print "$static\n";
> }
>
> foo( 'a');
> foo;
> foo( 'b');
> foo;
> }
It might be clearer if you used an example in which the calls were
outside the scope of the lexical variable, as is usually the case:
{
my $static = 'initial value';
sub foo {
$static = shift if @_;
print "$static\n";
}
};
# $static can't be seen here, but the sub calls still see it
foo( 'a');
foo;
foo( 'b');
foo;
Mike Guy
------------------------------
Date: 15 May 2001 16:41:05 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: static values in a subroutine
Message-Id: <9drm71$ceu$6@mamenchi.zrz.TU-Berlin.DE>
According to M.J.T. Guy <mjtg@cus.cam.ac.uk>:
> In article <9drl3f$ceu$4@mamenchi.zrz.TU-Berlin.DE>,
> Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> wrote:
> >
> >Just use your usual (lexical) variables in a scope that can be seen
> >when the sub is compiled:
> >
> > {
> > my $static;
> >
> > sub foo {
> > $static = shift if @_;
> > print "$static\n";
> > }
> >
> > foo( 'a');
> > foo;
> > foo( 'b');
> > foo;
> > }
>
> It might be clearer if you used an example in which the calls were
> outside the scope of the lexical variable, as is usually the case:
>
> {
> my $static = 'initial value';
>
> sub foo {
> $static = shift if @_;
> print "$static\n";
> }
> };
>
> # $static can't be seen here, but the sub calls still see it
> foo( 'a');
> foo;
> foo( 'b');
> foo;
Of course! That's what I intended to write (he said after having
it pointed out to him). Sorry, and thanks for catching it.
Anno
------------------------------
Date: Tue, 15 May 2001 16:58:19 GMT
From: Bart Lateur <bart.lateur@skynet.be>
Subject: Re: static values in a subroutine
Message-Id: <bvn2gt4gicqar2mml8btnmtrg03jsvam0m@4ax.com>
Travis Stevens wrote:
>I've been searching through my Programming Perl book and my Learning
>Perl book and have not found any information on this subject.
>Basically, I have a subroutine where I want to keep some values around
>so the next time I call the subroutine the values can be used. IE
>static varibles in C.
Save, er, declare them outside your sub. You can even share a variable
between two subs this way. Unless the code is in a "used" module, you
might need to initialize the variable in a BEGIN block.
{
my $foo; # variable static and shared
BEGIN {
$foo = "starting value";
}
sub foo1 {
$foo = shift;
}
sub foo2 {
return $foo;
}
}
--
Bart.
------------------------------
Date: Tue, 15 May 2001 16:59:25 -0000
From: cberry@cinenet.net (Craig Berry)
Subject: Re: static values in a subroutine
Message-Id: <tg2o3div3b12e3@corp.supernews.com>
Travis Stevens (Travis.Stevens@noaa.gov) wrote:
: I've been searching through my Programming Perl book and my Learning
: Perl book and have not found any information on this subject.
: Basically, I have a subroutine where I want to keep some values around
: so the next time I call the subroutine the values can be used. IE
: static varibles in C.
perldoc -q closure
--
| Craig Berry - http://www.cinenet.net/~cberry/
--*-- "God becomes as we are that we may be as he is."
| - William Blake
------------------------------
Date: Tue, 15 May 2001 12:47:26 -0500
From: "Mr. Sunray" <djberge@uswest.com>
Subject: Stumped on $?, duplicate output
Message-Id: <3B016BAE.FB6AC6EF@uswest.com>
Hi all,
I'm trying to test for the success or failure of a local ping-like
program that's simply "pcdfg -v". On success, it prints out "MyProgram
Version 1.0". I want to test for success, failure or a hang. Problem
is, its reporting both success AND failure. Any ideas?
I looked at perlvar and the docs on "open" (p.194, 2nd ed camel book).
I'm obviously missing something....
So, this is the code. Thanks in advance for any help.
Regards,
Mr. Sunray
# Both backtick and 'open()' methods tried
use IO::Handle;
...
# wrapped in eval to test for hang
eval{
alarm(30);
#`pdcfg -v`;
open(PDCFG, "pdcfg -v |");
PDCFG->autoflush(1); # Tried with and without
print $?, "\n"; # prints -1
print $? >> 8, "\n"; # prints 16777215
print $? & 127, "\n"; # prints 127
print $? & 128, "\n"; # prints 128
# Prints this...
if($?){
$msg = "Error communicating with PostD on $date<BR>\n";
$msg .= "PostD may not be running, or perhaps the Infranet
Server"
. " on Luey is down.<BR>\n";
print $socket $msg;
}
# ...and this
else{
print $socket "PostD is OK on $date<BR>\n";
}
close(PDCFG);
alarm(0);
};
# Specifically look for a timeout error
if($@){
if($@ =~ /timeout/){
$msg = "WARNING: PostD test utility not responding<BR>\n";
$msg .= "PostD is hanging. Too many possible causes to
list<BR>\n";
print $socket $msg;
}
else{
alarm(0);
die "pdcfg failed on $date\n";
}
}
------------------------------
Date: Tue, 15 May 2001 23:22:24 +1000
From: "Gregory Toomey" <gtoomey@usa.net>
Subject: Re: URGENT: CGI program wanted!
Message-Id: <7S9M6.27654$482.130997@newsfeeds.bigpond.com>
"muksca" <graphi@lineone.net> wrote in message
news:tg13coccc09731@corp.supernews.co.uk...
> Sorry to ask here only for weeks now I have tried other groups and
resources
> to no avail.
> Anyone here have or know of a perl script which does (or modification) the
> following...
...
Why don't you call in a consultant to do this. Oh, sorry, that's what you're
supposed to be doing.
gtoomey
------------------------------
Date: Tue, 15 May 2001 17:27:20 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: URGENT: CGI program wanted!
Message-Id: <x766f2a5fr.fsf@home.sysarch.com>
>>>>> "P" == Perlzagame <www@nospam.com> writes:
P> if this is off topic then 95% of the messages here are off-topic..
P> Try www.cgi-resources.com
that web site is off limits. you just marked yourself as a disciple of
the matt wright school of bad perl programming.
as for the OP request being off topic, this group is about discussing
the perl language and not about finding free programs.
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Learn Advanced Object Oriented Perl from Damian Conway - Boston, July 10-11
Class and Registration info: http://www.sysarch.com/perl/OOP_class.html
------------------------------
Date: 15 May 2001 15:20:53 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: use an expanding set of modules
Message-Id: <9drhgl$ceu$2@mamenchi.zrz.TU-Berlin.DE>
According to Dave Murray-Rust <dave@mo-seph.com>:
>
> Hello,
>
> I am currently writing a piece of software which builds up HTML pages
> out of a set of 'components'. Each component is represented by a
> package/class, one per module, which provides new, view, update etc.
> methods. At present, I am including each of these modules by hand
> everywhere I need them, which is obviously sub-optimal. Does anyone
> have any ideas for avoiding what seems like it must be a common
> problem? (I have tried perldoc, and etin)
>
> If it's of any help, a database is involved, and all the modules could
> be put in a specific directory
So what are you aiming for? Do you want a program to remain unchanged,
but change its behavior when you add or delete modules from a directory?
While somewhat unusual, this certainly can be done. Whether it's an
appropriate way must remain open until you have described your aim in
more detail.
Anno
------------------------------
Date: Tue, 15 May 2001 17:02:03 +0100
From: dave@mo-seph.com (Dave Murray-Rust)
Subject: Re: use an expanding set of modules
Message-Id: <slrn9g2knr.8eo.dave@flop.localnet>
On 15 May 2001 15:20:53 GMT, Anno Siegel
<anno4000@lublin.zrz.tu-berlin.de> wrote:
>> methods. At present, I am including each of these modules by hand
>> everywhere I need them, which is obviously sub-optimal. Does anyone
>
>So what are you aiming for? Do you want a program to remain unchanged,
>but change its behavior when you add or delete modules from a directory?
What I would like is to be able to add a new module, and have it
automagically use'd everywhere necessary.
>
>While somewhat unusual, this certainly can be done. Whether it's an
>appropriate way must remain open until you have described your aim in
>more detail.
I'll try and explain what I'm doing better (I still find this a hard
thing to do well, but here goes...)
I'm building pages out of 'components'. I would like to be able to add
a new type of component to the system, and have the following happen,
with a minimum of fuss:
- The module responsible for creating and displaying pages must use
the new component, in order to be able to instantiate objects
- At certain points, the user will be presented with a list of
components which they can add to a page, which should have new
components added to it.
I think it's a problem fairly analagous to plugins in audio/graphics
packages - you know that you are going to have many things which fill
a certain role, but you have no idea what they are ahead of time
(I still feel like I've left it quite vague, but I don't know how to
make it clearer without adding vast swathes of probably irrelevant
description - any pointers more than welcome)
Thanks for your time,
Dave
--
------------------------------
Date: 15 May 2001 17:01:16 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: use an expanding set of modules
Message-Id: <9drncs$i65$1@mamenchi.zrz.TU-Berlin.DE>
According to Dave Murray-Rust <dave@mo-seph.com>:
> On 15 May 2001 15:20:53 GMT, Anno Siegel
> <anno4000@lublin.zrz.tu-berlin.de> wrote:
> >> methods. At present, I am including each of these modules by hand
> >> everywhere I need them, which is obviously sub-optimal. Does anyone
> >
> >So what are you aiming for? Do you want a program to remain unchanged,
> >but change its behavior when you add or delete modules from a directory?
> What I would like is to be able to add a new module, and have it
> automagically use'd everywhere necessary.
> >
> >While somewhat unusual, this certainly can be done. Whether it's an
> >appropriate way must remain open until you have described your aim in
> >more detail.
>
> I'll try and explain what I'm doing better (I still find this a hard
> thing to do well, but here goes...)
>
> I'm building pages out of 'components'. I would like to be able to add
> a new type of component to the system, and have the following happen,
> with a minimum of fuss:
> - The module responsible for creating and displaying pages must use
> the new component, in order to be able to instantiate objects
> - At certain points, the user will be presented with a list of
> components which they can add to a page, which should have new
> components added to it.
>
> I think it's a problem fairly analagous to plugins in audio/graphics
> packages - you know that you are going to have many things which fill
> a certain role, but you have no idea what they are ahead of time
>
> (I still feel like I've left it quite vague, but I don't know how to
> make it clearer without adding vast swathes of probably irrelevant
> description - any pointers more than welcome)
You may want to employ a loader module for the main program to use().
Its task is to see what components (modules) are around and require()
them. It might have to know (beforehand) how to put class names
on various (or a single) module's @ISA. That way you'd get objects
that have or don't have certain methods, depending on which components
are installed. Generic base classes could provide fallback methods.
The general theme here is polymorphism, in this case inheritance
polymorphism. Damian Conway's excellent[1] OOP discusses these in a
Perl context.
Anno
[1] Is this book ever mentioned without this epithet?
------------------------------
Date: Tue, 15 May 2001 17:32:44 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: use an expanding set of modules
Message-Id: <x73da6a56r.fsf@home.sysarch.com>
>>>>> "AS" == Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> writes:
AS> The general theme here is polymorphism, in this case inheritance
AS> polymorphism. Damian Conway's excellent[1] OOP discusses these in a
AS> Perl context.
AS> [1] Is this book ever mentioned without this epithet?
i use a lot of epithets around damian in general. some are even curses
like goddamn, he is a nut case! or how the fuck did he think of that
idea? or darn it, my brane hurts from trying to grok perligata!
:)
and if you want to learn advanced OO Perl from the damian himself, take
his class:
http://www.sysarch.com/perl/OOP_class.html
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Learn Advanced Object Oriented Perl from Damian Conway - Boston, July 10-11
Class and Registration info: http://www.sysarch.com/perl/OOP_class.html
------------------------------
Date: 15 May 2001 17:43:48 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: use an expanding set of modules
Message-Id: <9drpsk$i65$5@mamenchi.zrz.TU-Berlin.DE>
According to Uri Guttman <uri@sysarch.com>:
> >>>>> "AS" == Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> writes:
>
> AS> The general theme here is polymorphism, in this case inheritance
> AS> polymorphism. Damian Conway's excellent[1] OOP discusses these in a
> AS> Perl context.
>
> AS> [1] Is this book ever mentioned without this epithet?
>
> i use a lot of epithets around damian in general. some are even curses
> like goddamn, he is a nut case! or how the fuck did he think of that
> idea? or darn it, my brane hurts from trying to grok perligata!
Perligata! A horror trip in stereo, where Perl and Latin scream left
and right under torture. I love it! In small doses.
Anno
------------------------------
Date: 15 May 2001 07:45:22 -0700
From: merlyn@stonehenge.com (Randal L. Schwartz)
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <m1bsour7r1.fsf@halfdome.holdit.com>
>>>>> "Godzilla!" == Godzilla! <godzilla@stomp.stomp.tokyo> writes:
Godzilla!> Mr. Karonen, I am asking something of you on
Godzilla!> behalf of the entire newsgroup.
In a continuing education course I attended last weekend, we looked
long and hard at this thing called "illusion" versus "objective
reality". And how many people seem to get stuck inside their head
living in a world of fantasy, because they are afraid to test theories
established when they were young. Theories that helped them through a
specific moment in time (often even in literal survival), but were now
being generalized to apply everywhere, and inappropriately. And how
damaging that can get, since no new information will come in, just a
replay of old information, or variations on that. In fact, I shared
with the group my conclusion was that the whole process "makes
tomorrow look like what you thought yesterday was".
Somehow, I find this a humorous coincidence to my newsreading this
morning. :-)
Hint to Kira - take a poll. Your statement above is completely
unsupportable, and undermines the rest of your message. You could
have simply asked for the offensive (to you) tagline to be removed.
Instead, by invoking a falsehood, you lose the entire request.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
------------------------------
Date: Tue, 15 May 2001 08:32:16 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <3B014C00.221BFF8@stomp.stomp.tokyo>
"Randal L. Schwartz" wrote:
> >>>>> "Godzilla!" == Godzilla! writes:
> Godzilla!> Mr. Karonen, I am asking something of you on
> Godzilla!> behalf of the entire newsgroup.
(unnoted snippage)
(snipped)
> Hint to Kira - take a poll. Your statement above is completely
> unsupportable, and undermines the rest of your message. You could
> have simply asked for the offensive (to you) tagline to be removed.
> Instead, by invoking a falsehood, you lose the entire request.
Well, well, look at you Randal. You are amongst the many here
who have publically announced themselves both promoters and
supporters of hatred, right along with your "Tad" character.
Godzilla!
------------------------------
Date: Tue, 15 May 2001 09:16:51 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <3B015673.E35EE523@stomp.stomp.tokyo>
Should this post twice, blame it on SuckerNews for
munching my first post attempt.
**
"Randal L. Schwartz" wrote:
> >>>>> "Godzilla!" == Godzilla! writes:
> Godzilla!> Mr. Karonen, I am asking something of you on
> Godzilla!> behalf of the entire newsgroup.
(unnoted snippage by Randal - context deliberately changed)
(snipped)
> Hint to Kira - take a poll. Your statement above is completely
> unsupportable, and undermines the rest of your message. You could
> have simply asked for the offensive (to you) tagline to be removed.
> Instead, by invoking a falsehood, you lose the entire request.
Well, well, look at you Randal. You are amongst the many here
who have publically announced themselves both promoters and
supporters of hatred, right along with your "Tad" character.
So, you gonna add an expression of hatred to your signature
file as others are doing?
Godzilla!
------------------------------
Date: 15 May 2001 09:46:00 -0700
From: merlyn@stonehenge.com (Randal L. Schwartz)
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <m1vgn2o913.fsf@halfdome.holdit.com>
>>>>> "Godzilla!" == Godzilla! <godzilla@stomp.stomp.tokyo> writes:
Godzilla!> So, you gonna add an expression of hatred to your signature
Godzilla!> file as others are doing?
Actually no. I don't "hate" you.
I think what you're doing often spreads inffective Perl memes, which I
then end up having to correct when I do code reviews or maintenance
rewrites for large companies. So in some senses, you're making
billable work for me. :) Why should I hate you for that? :)
And you do learn. I've seen lots of evidence for that over the
months. I was skeptical at first, but I've been pleasantly surprised.
But the way you argue with someone correcting you with objective
information or credible opinions has earned you an appropriate
reputation as a "troll". And if others wanna label you as that from
the get-go, I can't disagree with their right to do so.
I'm willing for you to change. I'm hoping so. But you'll be you,
every day, whether you're this way or that. For now, I can presume
that you're frightfully insecure, pretending to be very secure. It's
obvious in most of your postings. (And sometimes, it takes one to
know one. :) But the pretense is clear -- far too obvious for most,
and you're being called on your bluff from all sides, and that's
probably why you react as you do. You make more enemies than friends
that way... some so hostile that they put you in their .sig.
And that brings us full circle. :)
You want to get out of their .sig? Learn how to be less insecure, so
that you don't have to be so over-the-top arrogant in your responses
to people's responses. Simple, but could take you the rest of your
life to learn that one. I'm hoping sooner than that.
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
------------------------------
Date: 15 May 2001 17:23:00 GMT
From: ebohlman@omsdev.com (Eric Bohlman)
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <9drolk$hvm$2@bob.news.rcn.net>
Randal L. Schwartz <merlyn@stonehenge.com> wrote:
> I think what you're doing often spreads inffective Perl memes, which I
> then end up having to correct when I do code reviews or maintenance
> rewrites for large companies. So in some senses, you're making
> billable work for me. :) Why should I hate you for that? :)
I'd just like to point out that ineffective or incorrect Perl memes make
it all that much harder to convince managers that Perl should be used in
an organization, and that this is much more of a problem than with
ineffective VB, Java or C++ memes because Perl doesn't have slick
marketing behind it. So spreading bad code memes hurts the entire Perl
community.
------------------------------
Date: Tue, 15 May 2001 10:50:53 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: What is wrong with my Regular Expression?
Message-Id: <3B016C7D.A480387C@stomp.stomp.tokyo>
Eric Bohlman wrote:
> Randal L. Schwartz wrote:
> > I think what you're doing often spreads inffective Perl memes, which I
> > then end up having to correct when I do code reviews or maintenance
> > rewrites for large companies. So in some senses, you're making
> > billable work for me. :) Why should I hate you for that? :)
> I'd just like to point out that ineffective or incorrect Perl memes make
> it all that much harder to convince managers that Perl should be used in
> an organization, and that this is much more of a problem than with
> ineffective VB, Java or C++ memes because Perl doesn't have slick
> marketing behind it. So spreading bad code memes hurts the entire Perl
> community.
You are faced with a problem of who decides what is bad
coding and what rules are to be applied to decide what is
bad coding. Programming is an art, not a paradigm.
Within this group, my observation is and, this is supported
by posted articles, people decide what is bad based solely
on personal bias.
"My code is the best so yours is wrong."
If you boys are using this group to determine what code
is good and what code is bad, you have no business being
involved in programming art; your canvas is toilet paper.
Godzilla!
--
@ø=(a .. z);@Ø=qw(6 14 3 25 8 11 11 0 17 14 2 10 18);
$§="\n";$ß="\b";undef$©;print$§x($Ø[4]/2);
for($¡=0;$¡<=$Ø[2];$¡++){foreach$¶(@Ø){
$ø[$¶]=~tr/A-Z/a-z/;if(($¡==1)||($¡==$Ø[2]))
{$ø[$¶]=~tr/a-z/A-Z/;}print$ø[$¶];if($¶==0)
{print" ";}if($¶==$Ø[12]){print" !";}&D;}
print$ßx($Ø[4]*2);}print$§x($Ø[10]*2);
sub D{select$©,$©,$©,.25;}exit;
------------------------------
Date: 15 May 2001 17:18:07 GMT
From: steve@zeropps.uklinux.net (Steve)
Subject: Re: Worldclock program???
Message-Id: <slrn9g27oa.em8.steve@zero-pps.localdomain>
On Tue, 15 May 2001 10:18:44 +0100, Niall Byrne wrote:
>I have tried to look on the web sites for something similar that I could modify
>but with on luck,
On CPAN there's a web counter that has code in it that does something like that,
you'll need to take the relevant parts and adapt them to your needs, but it
should work. Think Subroutine!
--
Cheers
Steve email mailto:steve@zeropps.uklinux.net
%HAV-A-NICEDAY Error not enough coffee 0 pps.
web http://www.zeropps.uklinux.net/
or http://start.at/zero-pps
12:59pm up 102 days, 13:47, 2 users, load average: 1.32, 1.19, 1.08
------------------------------
Date: Tue, 15 May 2001 10:39:31 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: Worldclock program???
Message-Id: <3B0169D3.25A3DED@stomp.stomp.tokyo>
Niall Byrne wrote:
> I have been asked to created a worldclock that will appear
> on a web page to show the time of a number of countries at once.
(snipped)
> But my knowledge is nowhere near the level I need,
> So does anyone here have helpful comments or hints?
If you want to score points with the uppercrust, you
can do this by a display of resourcefulness in attaining
a goal, quickly and easily, above and beyond what is needed.
You can include links to a very nice variety of image displays
which include, local time, temperature, weather conditions and
many other features. I use this as a "magic" option in my
chatlines.
Here is a link to a very small, quick loading graphic which
updates itself every five minutes. You can backtrack to
the homepage of Weather Underground. Have a look; lots of
formats are available and free. This one is for my hometown,
Riverside, California. These are available for worldwide
locations. Very nice, very impressive and very reliable!
http://banners.wunderground.com/banner/gizmotimetemp/US/CA/Riverside.gif
Godzilla!
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 907
**************************************