Natural Language Principles in Perl

Learn it once, use it many times

Learn as you go

Many acceptable levels of competence

Multiple ways to say the same thing

No shame in borrowing

Indeterminate dimensionality

Local ambiguity is okay

1 & 2

&

&foo

In contrast, many strongly typed languages have ``distant'' ambiguity. C++ is one of the worst in this respect, because you can look at a + b and have no idea at all what the + is doing, let alone where it's defined. We send people to graduate school to learn to resolve distant ambiguities.

Punctuation by prosody and inflection

:-)

Some computer language designers seem to think that punctuation is evil; I doubt their English teachers would agree.

Disambiguation by number, case and word order

$dog

@dog

$

@

sub use

use sub

$

\

move $rook from => $qr_pos, to => "kb3";

Topicalization

foreach (@dog) { print $_ }

for ($some_long_name) { s/foo/bar/g; tr/a-z/A-Z/; print; }

/^Subject: (.*)/ and print $1;

Discourse structure

#!/usr/bin/perl

__END__

Pronominalization

$_

@_

$1

$2

$_

@_

@_

No theoretical axes to grind

Style not enforced except by peer pressure

Cooperative design

``Inevitable'' Divergence