[Chicago-talk] Two Perl curiosities
Alan Mead
amead2 at alanmead.org
Tue May 19 11:23:40 PDT 2015
On 5/19/2015 1:15 PM, Doug Bell wrote:
> $b always exists as a global variable, because it's used by sort().
> It's why people tend to avoid using $a and $b in examples or ever,
> because they could be clobbered by a sort() at any time.
I was not aware that a sort would clobber $a and $b, that's good to know.
> The : in variable declarations would allow you to set a variable's
> attributes, which is rarely used. In that syntax, Perl just thinks
> you've set no attributes.
Ah, I see.
--
Alan D. Mead, Ph.D.
President, Talent Algorithms Inc.
science + technology = better workers
+815.588.3846 (Office)
+267.334.4143 (Mobile)
http://www.alanmead.org
Announcing the Journal of Computerized Adaptive Testing (JCAT), a
peer-reviewed electronic journal designed to advance the science and
practice of computerized adaptive testing: http://www.iacat.org/jcat
More information about the Chicago-talk
mailing list