There's more than one way to do things | |
PerlMonks |
Re^5: why does push not default to $_?by pobocks (Chaplain) |
on Dec 06, 2008 at 23:36 UTC ( [id://728616]=note: print w/replies, xml ) | Need Help?? |
Even fairly regular natural languages (Latin, for instance) tend to have large numbers of irregularities, tending to cluster around the most commonly used words/concepts. English is, of course, a particularly non-standardized language, but it is, as the poster suggests, modeled after English. Specifically, the "default to '$_'/'@_'" functionality is modeled after default pronouns in English, and is certainly a key concern of this thread. The "then perl isn't your forte" was kind of a cheap shot, though. I'm not sure how non-orthogonal it is for a built-in to choose not to default to $_, especially given that most of the built-ins that do default are unary, to my knowledge.
for(split(" ","tsuJ rehtonA lreP rekcaH")){print reverse . " "}print "\b.\n";
In Section
Seekers of Perl Wisdom
|
|