Recent Changes - Search:




Main.Perl-Default-Variable History

Hide minor edits - Show changes to output

July 16, 2012, at 11:00 AM by -
Added lines 1-4:
!!"magic" scalars

Changed lines 13-17 from:


July 16, 2012, at 10:59 AM by -
Added lines 1-9:
There are a number of "magic" scalars with names that look like punctuation or line noise.
These special variables are used for all kinds of purposes, and are documented in perlvar.
The only one you need to know about for now is $_ which is the "default variable".
It's used as the default argument to a number of functions in Perl, and it's set
implicitly by certain looping constructs.

print; # prints contents of $_ by default
Edit - History - Print - Recent Changes - Search
Page last modified on July 16, 2012, at 11:00 AM