[30331] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1574 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sat May 24 09:09:47 2008

Date: Sat, 24 May 2008 06:09:09 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Sat, 24 May 2008     Volume: 11 Number: 1574

Today's topics:
        Delay in program execution <bill@ts1000.us>
    Re: FAQ 2.11 Perl Books (David Combs)
    Re: FAQ 2.11 Perl Books <brian.d.foy@gmail.com>
    Re: FAQ 5.18 How can I open a file with a leading ">" o <bill@ts1000.us>
    Re: FAQ 5.18 How can I open a file with a leading ">" o <benkasminbullock@gmail.com>
    Re: maintaining order in a hash (without Tie::IxHash) <ced@blv-sam-01.ca.boeing.com>
        new CPAN modules on Sat May 24 2008 (Randal Schwartz)
        Perl vs. Php <bill@ts1000.us>
    Re: Perl vs. Php sheinrich@my-deja.com
    Re: Perl vs. Php <benkasminbullock@gmail.com>
    Re: Range of number (aka ? the Platypus)
    Re: reference/alias in perl vs reference/alias in C++ <cdalten@gmail.com>
        Regex for password checking <xemoth@gmail.com>
    Re: Regex for password checking <joe@inwap.com>
    Re: Strawberry <mjcarman@mchsi.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Sat, 24 May 2008 03:26:05 -0700 (PDT)
From: Bill H <bill@ts1000.us>
Subject: Delay in program execution
Message-Id: <0bbf628c-f773-4eae-8442-53178d39a446@l64g2000hse.googlegroups.com>

I have a website where I use a shareware store written in Perl that
contains 40+ modules. It runs very fast, but I have noticed over the
years, if I make changes to a module's code and post it, there is a 3
or 4 second delay in its execution the first time I run it, then every
other time it runs with no delay. I know (or believe strongly) perl
compiles the source for running the program, but does it keep this
compiled version around for later use unless you change the code and
then it will compile it again (that is the only reason I can think of
for the delay).

I am not running any mod_perl and this is running on an Apache server
under linux.

Bill H


------------------------------

Date: Sat, 24 May 2008 08:04:18 +0000 (UTC)
From: dkcombs@panix.com (David Combs)
Subject: Re: FAQ 2.11 Perl Books
Message-Id: <g18i62$fdm$1@reader2.panix.com>

In article <200520081213523682%brian.d.foy@gmail.com>,
brian d foy  <brian.d.foy@gmail.com> wrote:
>In article <g0qr8h$cte$1@reader2.panix.com>, David Combs
><dkcombs@panix.com> wrote:
>
>
>> ----
>> 
>> Well, I've tried.  Breaking into a clique is really hard.
>> 
>
>If you want to accuse me of something, just come out and say it. That
>you had to invoke some "clique" twice in your *first* message about the
>subject.

Hey, brian, I wasn't talking about you -- I was simply setting
forth an observation made over some number of years reading
this truly amazing (wonderful) group.

And my follow up wasn't to any particular person -- I just
saw the FAQ post-for-comments, and was responding to
the *subject*, books on perl, and on publicizing their
existance and maybe even a blurb about them.

And if subsconsciously there has developed at least a bit or sense of
clique of authors -- well, no big surprise, would
likely happen to me too.

First of all, so many publish via O'Reilly (thank god for O'Reilly!),
and that might tend to bond, and more importantly, because
of the enormous (thankless) work you guys do here in this
group, and in yapc, and other perl conferences and doings,
all without any pay, just from an innate desire to contribute,
that also bonds together.


Anyway, of all the books on perl (Perl) I've seen in bookstores
(my hobby -- bookstores), this Pro Perl is the only one that's
(in my opinion) is equally really good as the ones we all know
but *isn't* (or sure doesn't seem to be) "known".


-----

Look, Perl has competitors, and listening around I hear
complaints about Perl being hard to read, looks like apl
or teco, etc, etc, and even though all those complaints
are just plain wrong (seems to me), people (and employers!)
listen to them, and it has an effect, maybe a *big* effect.

Perl is really great!  And the brainpower behind it, wow,
I can't imagine that any of the competitors have anything like
that idea-and-cs-knowledge base.

Given that lots of Perl users depend on it for their living,
either as employees or as consultants, seems to me that the
easier we make it to learn (and there's a *lot* to learn!),
the better for everyone, including the popularity of the language
itself.

----

All I ask is that a few trustworthy people have a look at
this thing I'm talking about.

And it'd be best it it were Perl AUTHORS who did the
looking, so that if any gave it a thumbs-up, you'd
know, I think, that the opinion wasn't B.S.

My own belief is that this thing would be one of the
candidates for a "first" Perl book to read.

(A "first" Perl book would seem to be to be terribly
difficult to write -- I think this guy has done
a surprisingly good job in a very difficult task.)

--------


Since it was you who responded to my post, and you 
have also produced perl texts, how about *you*?

If I had Bookpool send you one, would you spend maybe
30 minutes on it?

Any other author interested?  Maybe I could dig real deep
and find enough money to do two or three.

Then, if it seems worth looking at, then take it (them?) to yapc and
pass it around, maybe.

Or maybe I could call the publisher and ask them to
send several out to perl-authors who volunteer the
30 minutes look-see?  (Who knows, maybe they'd (publisher) do it.)


Again, whatever tools we can find to make it more likely
for someone to at least *try* perl, the better for
everyone!

Certainly one person who should see it is Larry -- heck,
maybe he already has?


-----

Sorry if you thought I was attacking *you* in some way.
NO WAY, EVER!

I do hope that more than just you see this response.

Believe it or not, I'm simply trying to help!


David




------------------------------

Date: Sat, 24 May 2008 11:40:58 +0200
From: brian d  foy <brian.d.foy@gmail.com>
Subject: Re: FAQ 2.11 Perl Books
Message-Id: <240520081140581251%brian.d.foy@gmail.com>

In article <g18i62$fdm$1@reader2.panix.com>, David Combs
<dkcombs@panix.com> wrote:

> In article <200520081213523682%brian.d.foy@gmail.com>,
> brian d foy  <brian.d.foy@gmail.com> wrote:
> >In article <g0qr8h$cte$1@reader2.panix.com>, David Combs
> ><dkcombs@panix.com> wrote:
> >
> >
> >> ----
> >> 
> >> Well, I've tried.  Breaking into a clique is really hard.
> >> 
> >
> >If you want to accuse me of something, just come out and say it. That
> >you had to invoke some "clique" twice in your *first* message about the
> >subject.
> 
> Hey, brian, I wasn't talking about you -- I was simply setting

> All I ask is that a few trustworthy people have a look at
> this thing I'm talking about.
> 
> And it'd be best it it were Perl AUTHORS who did the
> looking, so that if any gave it a thumbs-up, you'd
> know, I think, that the opinion wasn't B.S.

Again, what are you acusing me of? I'm the guy that maintains the FAQ,
and I'm a Perl Author. I'm not trustworthy? My opinion is bullshit?

I read all the Perl books that come out. Publishers already send me the
books as they are published (and often before they are published).


I still have nio idea what you are proposing, but it sure looks like
you're trying to say that I have an ethical problem maintaining the
FAQ. If you have a problem or a patch, follow the instructions at the
end of each FAQ posting.


------------------------------

Date: Sat, 24 May 2008 03:20:49 -0700 (PDT)
From: Bill H <bill@ts1000.us>
Subject: Re: FAQ 5.18 How can I open a file with a leading ">" or trailing  blanks?
Message-Id: <2122e173-acf8-4ea8-a395-18d12534b0d0@y21g2000hsf.googlegroups.com>

[snip]
> 5.18: How can I open a file with a leading ">" or trailing blanks?
>
> =A0 =A0 (contributed by Brian McCauley)
>
> =A0 =A0 The special two argument form of Perl's open() function ignores tr=
ailing
> =A0 =A0 blanks in filenames and infers the mode from certain leading chara=
cters
> =A0 =A0 (or a trailing "|"). In older versions of Perl this was the only v=
ersion
> =A0 =A0 of open() and so it is prevalent in old code and books.
>
> =A0 =A0 Unless you have a particular reason to use the two argument form y=
ou
> =A0 =A0 should use the three argument form of open() which does not treat =
any
> =A0 =A0 characters in the filename as special.
>
> =A0 =A0 =A0 =A0 =A0 =A0 open FILE, "<", " =A0file =A0"; =A0# filename is "=
 =A0 file =A0 "
> =A0 =A0 =A0 =A0 =A0 =A0 open FILE, ">", ">file"; =A0 =A0 # filename is ">f=
ile"
>
> --------------------------------------------------------------------
[snip]

Other than the reasons given above, is there any effeciency or speed
benefits to using:

open FILE, ">", "file";

instead of:

open(FILE,">file");

does the former skip a parser step that could could increase the speed
of a program (or its compilation)?

Bill H

Bill H


------------------------------

Date: Sat, 24 May 2008 13:05:59 +0000 (UTC)
From: Ben Bullock <benkasminbullock@gmail.com>
Subject: Re: FAQ 5.18 How can I open a file with a leading ">" or trailing  blanks?
Message-Id: <g193rn$pp1$2@ml.accsnet.ne.jp>

On Sat, 24 May 2008 03:20:49 -0700, Bill H wrote:

> is there any effeciency or speed
> benefits to using:
> 
> open FILE, ">", "file";
> 
> instead of:
> 
> open(FILE,">file");
> 
> does the former skip a parser step that could could increase the speed
> of a program (or its compilation)?

I don't think there are any speed or efficiency benefits, and even if they 
were, since Perl is already very fast, the amount of benefit would be dwarfed 
by the cost of the operating system call to open the file. Some reasons for 
using the three argument form of open can be found in "perldoc -f open".


------------------------------

Date: Sat, 24 May 2008 04:12:24 -0700 (PDT)
From: "comp.llang.perl.moderated" <ced@blv-sam-01.ca.boeing.com>
Subject: Re: maintaining order in a hash (without Tie::IxHash)
Message-Id: <3c93b08d-7c71-434f-ae68-fdb8623a260d@f24g2000prh.googlegroups.com>

On May 22, 12:50 pm, J=FCrgen Exner <jurge...@hotmail.com> wrote:
> nolo contendere <simon.c...@fmr.com> wrote:
> >However, regarding the problem of maintaining sort order of a hash,
> >and the Tie::IxHash module, I have a question.
>
> Maybe I am old-fashioned but to me 'sorted' and 'hash' is a
> contradiction in terms. A hash is a (partial) mapping from string to
> scalar and mappings do not have a sequence.
> Arrays are different because their domain (natural numbers) does have a
> natural order, therefore arrays inherit this order.
>
> If you are trying to force an order on a hash then probably you are
> using the wrong data structure in the first place and you would be
> better off using an array.
>
I agree mostly. But, even stretching the hash's natural model a bit,
an ordered hash is a convenient amenity at times.  Also, with a big
array and lots of lookups, even a slow tied hash could be faster.

--
Charles DeRykus



------------------------------

Date: Sat, 24 May 2008 04:42:18 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Sat May 24 2008
Message-Id: <K1CvqI.1qvG@zorch.sf-bay.org>

The following modules have recently been added to or updated in the
Comprehensive Perl Archive Network (CPAN).  You can install them using the
instructions in the 'perlmodinstall' page included with your Perl
distribution.

AI-NeuralNet-SOM-0.06
http://search.cpan.org/~drrho/AI-NeuralNet-SOM-0.06/
Perl extension for Kohonen Maps 
----
Abstract-Meta-Class-0.04
http://search.cpan.org/~adrianwit/Abstract-Meta-Class-0.04/
Simple meta object protocol implementation. 
----
Apache-SWIT-0.34
http://search.cpan.org/~bosu/Apache-SWIT-0.34/
mod_perl based application server with integrated testing. 
----
Apache2-ASP-1.46
http://search.cpan.org/~johnd/Apache2-ASP-1.46/
Perl extension for ASP on mod_perl2. 
----
Apache2-AuthPAM-0.01
http://search.cpan.org/~timb/Apache2-AuthPAM-0.01/
Authenticate apache request using PAM services 
----
CPAN-1.92_62
http://search.cpan.org/~andk/CPAN-1.92_62/
query, download and build perl modules from CPAN sites 
----
CPAN-Mini-0.571
http://search.cpan.org/~rjbs/CPAN-Mini-0.571/
create a minimal mirror of CPAN 
----
Carp-POE-0.01
http://search.cpan.org/~hinrik/Carp-POE-0.01/
Carp adapted to POE 
----
Carp-POE-0.02
http://search.cpan.org/~hinrik/Carp-POE-0.02/
Carp adapted to POE 
----
Catalyst-Plugin-ConfigComponents-0.1.21
http://search.cpan.org/~pjfl/Catalyst-Plugin-ConfigComponents-0.1.21/
Creates components from config entries 
----
Catalyst-Plugin-InflateMore-0.1.11
http://search.cpan.org/~pjfl/Catalyst-Plugin-InflateMore-0.1.11/
Inflates symbols in application config 
----
Config-Model-Sshd-0.101
http://search.cpan.org/~ddumont/Config-Model-Sshd-0.101/
----
Config-Model-Sshd-0.102
http://search.cpan.org/~ddumont/Config-Model-Sshd-0.102/
----
DBD-Unify-0.72
http://search.cpan.org/~hmbrand/DBD-Unify-0.72/
DBI driver for Unify database systems 
----
DBIx-SchemaChecksum-0.03
http://search.cpan.org/~domm/DBIx-SchemaChecksum-0.03/
Generate and compare checksums of database schematas 
----
DBIx-SchemaChecksum-0.04
http://search.cpan.org/~domm/DBIx-SchemaChecksum-0.04/
Generate and compare checksums of database schematas 
----
Data-CloudWeights-0.2.50
http://search.cpan.org/~pjfl/Data-CloudWeights-0.2.50/
Calculate values for an HTML tag cloud 
----
Data-Validation-0.1.16
http://search.cpan.org/~pjfl/Data-Validation-0.1.16/
Check data values form conformance with constraints 
----
Devel-Autoflush-0.02
http://search.cpan.org/~dagolden/Devel-Autoflush-0.02/
Set autoflush from the command line 
----
Devel-NYTProf-1.13
http://search.cpan.org/~akaplan/Devel-NYTProf-1.13/
line-by-line code profiler and report generator 
----
Devel-NYTProf-1.14
http://search.cpan.org/~akaplan/Devel-NYTProf-1.14/
line-by-line code profiler and report generator 
----
HTML-Accessors-0.1.23
http://search.cpan.org/~pjfl/HTML-Accessors-0.1.23/
Generate HTML elements 
----
Helios-Panoptes-1.29_01
http://search.cpan.org/~lajandy/Helios-Panoptes-1.29_01/
CGI::Application providing web admin interface to Helios distributed job processing system 
----
IPC-SRLock-0.1.52
http://search.cpan.org/~pjfl/IPC-SRLock-0.1.52/
Set/reset locking semantics to single thread processes 
----
Lingua-Translate-0.09
http://search.cpan.org/~samv/Lingua-Translate-0.09/
Translate text from one language to another 
----
List-Compare-0.36
http://search.cpan.org/~jkeenan/List-Compare-0.36/
Compare elements of two or more lists 
----
MIME-Types-1.24
http://search.cpan.org/~markov/MIME-Types-1.24/
Definition of MIME types 
----
Math-Random-MT-Perl-1.03
http://search.cpan.org/~jfreeman/Math-Random-MT-Perl-1.03/
Pure Perl Pseudorandom Number Generator 
----
Media-DateTime-0.43
http://search.cpan.org/~mgrimes/Media-DateTime-0.43/
An highly extensible module to extract the creation date and time from a file. 
----
Nagios-Plugin-DieNicely-0.01
http://search.cpan.org/~jlmartin/Nagios-Plugin-DieNicely-0.01/
Die in a Nagios output compatible way 
----
POE-XUL-0.0400
http://search.cpan.org/~gwyn/POE-XUL-0.0400/
Framework for remote XUL application in POE 
----
POE-XUL-0.0401
http://search.cpan.org/~gwyn/POE-XUL-0.0401/
Framework for remote XUL application in POE 
----
POE-XUL-0.0402
http://search.cpan.org/~gwyn/POE-XUL-0.0402/
Framework for remote XUL application in POE 
----
POE-XUL-0.0403
http://search.cpan.org/~gwyn/POE-XUL-0.0403/
Framework for remote XUL application in POE 
----
POE-XUL-0.0404
http://search.cpan.org/~gwyn/POE-XUL-0.0404/
Framework for remote XUL application in POE 
----
Pod-HtmlEasy-1.0101
http://search.cpan.org/~gleach/Pod-HtmlEasy-1.0101/
Generate personalized HTML from PODs. 
----
Postgres-Handler-HTML-1
http://search.cpan.org/~csa/Postgres-Handler-HTML-1/
HTML Component for PostgreSQL data. 
----
Regexp-Common-time-0.02
http://search.cpan.org/~roode/Regexp-Common-time-0.02/
Date and time regexps. 
----
Rose-DBx-Garden-0.13
http://search.cpan.org/~karman/Rose-DBx-Garden-0.13/
bootstrap Rose::DB::Object and Rose::HTML::Form classes 
----
Term-GentooFunctions-1.2.0
http://search.cpan.org/~jettero/Term-GentooFunctions-1.2.0/
provides gentoo's einfo, ewarn, eerror, ebegin and eend. 
----
Wurst-0.51c
http://search.cpan.org/~wurst/Wurst-0.51c/
Perl extension for playing with alignment methods 
----
ZConf-0.0.3
http://search.cpan.org/~vvelox/ZConf-0.0.3/
A configuration system allowing for either file or LDAP backed storage. 
----
ZConf-0.0.4
http://search.cpan.org/~vvelox/ZConf-0.0.4/
A configuration system allowing for either file or LDAP backed storage. 
----
autobox-Core-0.5
http://search.cpan.org/~swalters/autobox-Core-0.5/
Methods for core built-in functions in primitive types 
----
mc_units-20080523
http://search.cpan.org/~hmbrand/mc_units-20080523/
----
mylib-1.00
http://search.cpan.org/~gaas/mylib-1.00/
add private lib to the module search path 
----
pfacter-1.13-2
http://search.cpan.org/~sschneid/pfacter-1.13-2/
Collect and display facts about the system 
----
pfacter-1.13-3
http://search.cpan.org/~sschneid/pfacter-1.13-3/
Collect and display facts about the system 


If you're an author of one of these modules, please submit a detailed
announcement to comp.lang.perl.announce, and we'll pass it along.

This message was generated by a Perl program described in my Linux
Magazine column, which can be found on-line (along with more than
200 other freely available past column articles) at
  http://www.stonehenge.com/merlyn/LinuxMag/col82.html

print "Just another Perl hacker," # the original

--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion


------------------------------

Date: Sat, 24 May 2008 03:32:14 -0700 (PDT)
From: Bill H <bill@ts1000.us>
Subject: Perl vs. Php
Message-Id: <60f3f974-7932-41f3-9807-9496c9550931@m3g2000hsc.googlegroups.com>

Preface: This is not a flame war, please don't turn it into one.

I am involved in a very large project that  will be doing a lot of
talking to Postgres databases (possibly using a a RST middleware). The
database guys want to use php for all of their stuff, I want to use
perl for mine. The reasons I want to use perl are:

1) I have been working in it for 10+ years
2) I have 10's of thousands lines of code written (some very complex
creating pdf's on the fly etc)

Is there a valid reason I should switch to php versus perl (or vice
versa they switch to perl)? Portability, ease of maintaining, speed of
execution, security etc?

Bill H


------------------------------

Date: Sat, 24 May 2008 03:51:12 -0700 (PDT)
From: sheinrich@my-deja.com
Subject: Re: Perl vs. Php
Message-Id: <ff4e0b48-3108-4f03-9afc-1fe3497accb1@d77g2000hsb.googlegroups.com>

On May 24, 12:32 pm, Bill H <b...@ts1000.us> wrote:
> Preface: This is not a flame war, please don't turn it into one.
>
> I am involved in a very large project that  will be doing a lot of
> talking to Postgres databases (possibly using a a RST middleware). The
> database guys want to use php for all of their stuff, I want to use
> perl for mine. The reasons I want to use perl are:
>
> 1) I have been working in it for 10+ years
> 2) I have 10's of thousands lines of code written (some very complex
> creating pdf's on the fly etc)
>
> Is there a valid reason I should switch to php versus perl (or vice
Yup.
_They_ are probably more than one.
;-)
And unless they are equally (in)experienced in both languages it is
more likely you will have to give way. Given that they are favouring
PHP over Perl I doubt that this will be the case.

> versa they switch to perl)? Portability, ease of maintaining, speed of
> execution, security etc?
>
> Bill H
IMHO the generic database interface of Perl is better suited to
enforce writing a readable and secure access code.

Apart from that I think that both languages can be used to write good
or bad, insecure and inefficent programs. Having savvy people is far
more important than the decision for either language.

Steffen


------------------------------

Date: Sat, 24 May 2008 13:00:04 +0000 (UTC)
From: Ben Bullock <benkasminbullock@gmail.com>
Subject: Re: Perl vs. Php
Message-Id: <g193gk$pp1$1@ml.accsnet.ne.jp>

On Sat, 24 May 2008 03:32:14 -0700, Bill H wrote:

> Preface: This is not a flame war, please don't turn it into one.
> 
> I am involved in a very large project that  will be doing a lot of
> talking to Postgres databases (possibly using a a RST middleware). The
> database guys want to use php for all of their stuff, I want to use perl
> for mine. The reasons I want to use perl are:
> 
> 1) I have been working in it for 10+ years 2) I have 10's of thousands
> lines of code written (some very complex creating pdf's on the fly etc)
> 
> Is there a valid reason I should switch to php versus perl (or vice
> versa they switch to perl)? Portability, ease of maintaining, speed of
> execution, security etc?

The obvious difference is that PHP basically runs inside web servers, whereas 
Perl is basically a standalone program. Using PHP with a web server like 
Apache is much faster than using Perl CGI scripts, and it's much simpler to 
use PHP scripts than it is to set up mod_perl so that the Perl runs at 
comparable speeds.

PHP is basically an outgrowth of Perl 4, and a lot of Perl people have pointed 
to PHP and said it's not a good language, but I'm not convinced - web 
applications built on PHP seem to work well.

If I had to do this job, though, I'd choose to use Perl anyway, because then I 
wouldn't have to spend a lot of time learning PHP, and I could use all those 
handy CPAN modules.


------------------------------

Date: Sat, 24 May 2008 07:38:09 GMT
From: "David Formosa (aka ? the Platypus)" <dformosa@usyd.edu.au>
Subject: Re: Range of number
Message-Id: <slrng3fifc.24i.dformosa@localhost.localdomain>

On 23 May 2008 19:57:24 GMT, Abigail <abigail@abigail.be> wrote:

[...]


> As for other languages, IIRC, chained comparisons have always worked the
> way they will in Perl 6. 

Perl 6 will be the first language I know of that will do chained comparisions.
Most others do them wrong.  For example in C

    (2<1<3) 

Will return true, while in other languages such a chained comparison is a
type error.


------------------------------

Date: Fri, 23 May 2008 21:32:21 -0700 (PDT)
From: grocery_stocker <cdalten@gmail.com>
Subject: Re: reference/alias in perl vs reference/alias in C++
Message-Id: <5d0dd43b-17c2-420d-911d-2f414d1840b7@x19g2000prg.googlegroups.com>

On May 23, 3:44=A0pm, "A. Sinan Unur" <1...@llenroc.ude.invalid> wrote:
> grocery_stocker <cdal...@gmail.com> wrote innews:7e2f37b0-b75a-4f1e-b6d4-5=
8c93a5d12ea@q27g2000prf.googlegroups.com:
>
> > On May 23, 12:22 pm, Jim Gibson <jimsgib...@gmail.com> wrote:
> >> In article
> >> <8f8a7081-f03a-4063-9999-36ba6dd16...@u12g2000prd.googlegroups.com>,
>
> >> grocery_stocker <cdal...@gmail.com> wrote:
> >> > How are references and aliases in perl different than references in
> >> > aliases in C++?
>
> [ snip Jim's explanation ]
>
> >> --
> >> Jim Gibson
>
> [ Do *NOT* quote sigs ]
>
> > Everytime I ask a question on the newsgroup, i keep on thinking "I'm
> > sure things would have been a lot easier if I would have taken more
> > than 6 week of FORTRAN."
>
> I did do some FORTRAN programming almost 20 years ago. I am not sure
> what you are getting at though.

Well, FORTRAN was my first formal introduction to structured
programming. Is 6 weeks enough to actually learn how to think
logically?
>
> > I don't care what anyone says.
>
> Well, I am reminded of
>
> http://www.catb.org/~esr/faqs/hacker-howto.html#believe5
>
> > Learning to program on your own.
>
> http://en.wikipedia.org/wiki/Sentence_%28linguistics%29
>
> > mastering the core concepts without formal
> > schooling, and then actually making it as a programmer takes a certain
> > level of skill and internal drive.
>
> Are you referring to yourself here?
>

No. I think some people that come mind are certain former Netscape and
FreeBSD engineers.

> I am not sure what "making it as a programmer" means above. On the other
> hand, almost everyday at work is an opportunity for me to run into
> someone who thinks he/she has made it as a programmer. I am not sure I
> agree with those people's self-assessments.
>
> > Not everyone has it.
>
> True.
>
> > I think I only know a few people with no more than a high school
> > education that are doing the same kind of work, for the exact same
> > pay, as a person with an advanced degree in the sciences.
>
> The only thing that shows me is that the person with the advanced degree
> in the sciences has chosen not to work in the field in which he/she
> earned the degree.
>
> Clearly, once one has a certain mental capability, whether one chooses
> to invest time in an advanced degree is a matter of preference. Another
> person with even superior mental capacity may choose not to "waste" five
> to seven years toiling on a project which is of interest to only a few
> people and which, as a norm, do not generate huge monetary returns on
> that investment. This is why I do not put much stock in letters before
> or after a person's name.
>
> Achieving that goal also takes a certain level of skill and drive.
>
> If I were you, I would not be so quick to pat myself on the back for
> this particular reason until I were able to compete with Physics Ph.D.'s
> in the fields in which they earned their degrees.
>
> You can be proud of your achievements without resorting to this silly
> argument.
>
> Switching back to discussing Perl ... now.
>

Yes. We now go back to our regular discussion on Perl.


------------------------------

Date: Fri, 23 May 2008 20:16:42 -0700 (PDT)
From: Owen <xemoth@gmail.com>
Subject: Regex for password checking
Message-Id: <d7f42fb3-1b1f-4c2d-a089-d5ef9e330306@k10g2000prm.googlegroups.com>

Hi,

Just wondering if [:print:], with a pretest for a space would meet all
the requirements of a unix password. (mixed case, numbers, and
symbols)

Or is there some easier way of doing it?

TIA


Owen


#!/usr/bin/perl -w

use strict;

while (<DATA>) {
    chomp;
    my $new_pass = $_;
    if ( $new_pass =~ / / ) { print "$new_pass Error, contains space
\n" }

    #unless ( $new_pass =~ /[a-zA-Z0-9_\\\^\.\|\(\)\[\]\`~!@#%&*;:'"+,?
\/><]/ )
    #unless ( $new_pass =~ /[[:alnum:]_\\\^\.\|\(\)\[\]\`~!@#%&*;:'"+,?
\/]></ )

    #unless ( $new_pass =~ /[[:alnum:][:print:]]/ )
    unless ( $new_pass =~ /[[:print:]]/ )
    {
        print "$new_pass Error, not printable\n";
    }
}

__DATA__
Ddfrew3>
cF4444!,


------------------------------

Date: Fri, 23 May 2008 23:44:54 -0700
From: Joe Smith <joe@inwap.com>
Subject: Re: Regex for password checking
Message-Id: <O5Gdnez4l_jxJKrVnZ2dnUVZ_rzinZ2d@comcast.com>

Owen wrote:
> Just wondering if [:print:], with a pretest for a space would meet all
> the requirements of a unix password. (mixed case, numbers, and
> symbols)
> 
> Or is there some easier way of doing it?

I'd say it is more straightforward to make such tests one at a time.

   my $good = 0;
   ++$good if /[a-z]/;
   ++$good if /[A-Z]/;
   ++$good if /[0-9]/;
   ++$good if /\W/;
   redo unless $good >= 3;

	-Joe
                                                           Doctor Who?


------------------------------

Date: Sat, 24 May 2008 02:34:46 GMT
From: Michael Carman <mjcarman@mchsi.com>
Subject: Re: Strawberry
Message-Id: <a9LZj.122959$TT4.110983@attbi_s22>

A. Sinan Unur wrote:
> Michael Carman <mjcarman@mchsi.com> wrote:
>> I don't recall ActivePerl ever giving me an option to install 
>> anywhere other than C:\Perl.
> 
> Instead of arguing here, why not try it yourself? Of course there is 
> an option to change the installation location.

Who's arguing? I'm trying to learn how you apparently did something that
I didn't think could be done (at least not easily).

I re-ran one of the installers and now see where I went astray. You
*can* change the installation path but the installer gives the strong
impression that it's hard-coded:

* The path is displayed in a borderless label widget instead of
   an entry, so you can't simply type your preferred path.
* The browse button to change the path is on the far opposite side of
   the dialog making it appear disconnected from the path label.
* The browse button disappears entirely as soon as you focus any of
   the sub-options (e.g. to opt to not install the examples).

I normally opt out of some of the components so by the time I read
down to where the path is the button is gone and all I can see is
the label.

> The key is to keep the global environment clean and pointing to the
> system default Perl installation. Then, use the other installations
> appropriately setup cmd shells.

Ah, there's the trick. Good call.

Thanks for the tips.

-mjc


------------------------------

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.  

NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

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 V11 Issue 1574
***************************************


home help back first fref pref prev next nref lref last post