On Jun 10, 2:07 am, chas.ow...@gmail.com ("Chas. Owens") wrote:
> On Thu, Jun 10, 2010 at 00:59, C.DeRykus <dery...@gmail.com> wrote:
>
> snip> Not that I know of but you write your own subroutine
> > using the index code you've shown. Nearly trivial to
> > do and, after all, plagiarism is a virtue :)
>
> snip
>
> I know that this was meant as a joke, but plagiarism is not a virtue
> in the Perl community; our virtues are [Laziness, Impatience, and
> Hubris][1].  Stealing code definitely falls under Laziness, but the
> truly Lazy thing to do is to document where it came from (so you can
> find it again).  By documenting where it came from, you are no longer
> plagiarizing (but you may be violating copyright).
>

Hm, yes it was a joke. And for something simple, like
finding substrings, there's no compelling reason to
document some tiny code snippet you've chosen to
re-use. Perhaps, on the other hand, if you find a
really good  explanation of a tricky point or a good
benchmark  technique, then....yes.

The more important point IMO is that Perl  is built
on code re-use. Apocryphal or not, someone said
Guido privately whined that Larry had stolen many
of Python's OO ideas. Whether it's a CPAN search
or a quick lookup of a code snippet/idiom that'd make
the job easier, there's no sin attached.  Rolling your
own is a kind of false hubris. And  expecting language
built-in's for every simple task is hubris-deficiency.
"Plagiarism is a virtue" is hyperbole of course but a
good reminder of what Perl's all about.

--
Charles DeRykus


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to