Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: Perl array declaring

by sundialsvc4 (Abbot)
on Jun 02, 2013 at 16:54 UTC ( #1036599=note: print w/replies, xml ) Need Help??

in reply to Perl array declaring

Especially to one “new to Perl,” let us repeat this very critical mantra:   always begin your programs with:

use strict;
use warnings;

This will probably cause new error-messages to be generated, and you should adjust your source-code as needed to eliminate them.   Quite a number of bugs and “inexplicable behaviors” will be squeezed-out by doing this.

Perl is very much a “DWIM = Do What I Mean” language.   Rightly or wrongly, it doesn’t impose many strictures upon what you write.   It will try to adopt an interpretation that works, and, with it, to do what it thinks you mean.   These two declarations will cause it be less-tolerant and more-strict ... flushing-out more errors at compile time.   (The antonym of use is no, which you will occasionally also see in production code.)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1036599]
[karlgoethebier]: marioroy: Checkout also "Linear Expressions" by the same author...
[marioroy]: thanks karlgoethebier.

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (17)
As of 2017-03-24 10:22 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (298 votes). Check out past polls.