|No such thing as a small change|
Re: My questions: new to perlby ikegami (Pope)
|on Mar 13, 2011 at 06:29 UTC||Need Help??|
To explain the differences, there would have to similarities.
my creates a lexically scoped variable.
local temporarily saves a package variable, (Upd: array element or hash element. ) The previous value of the variable will be restored when the current scope is exited.
See perlrun for -w and -T.
strict detects errors that aren't detected by default for backwards compatibility reasons.
Assign to %ENV. See perlvar.
use warnings; detects lots of situations which are very likely to have resulted from errors.
"Scalar data" is by no means a formal term. I've never heard it. It probably refers to values that can be assigned to a scalar.
Scalar variables are one of Perl's variable types. They hold one* the following: a string, a signed integer, an unsigned integer, a floating point number, a string (array of 8-bit characters), a string (array of 32/64-bit characters), a reference or a glob.
(Upd: See perldata. )
* — Sometimes more than one, such as both the integer 123 and the string "123". These are optimisations or very special cases called "dualvars".
They are provided in @ARGV. See perlvar.
If there isn't, it's because noone coded a way of doing it.
By definition, hashes can't be sorted. Their keys or values can be sorted.
(Upd: Magic can be used to alter their implementation. See reply for some modules that do this. )