- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
i/p i/p array!
Admin
Awrhh! That's an awrticle gone awry!
Admin
The only thing that I can think of is the author having a Perl background, since it's common to use (my $foo, my $bar) = @_ as the first line in functions to give the parameters actual names. However, this WTF is doing exactly the opposite ... eh, I'm out of ideas.
Admin
So this function assumes everyone is male (Mr. )...
Admin
It doesn't matter that $fullName assignment doesn't work as intended, because the result is never used anyway.
Two articles in a row where, no matter who you are, you get "Mr" added to their name and then taken away again. I guess we shouldn't be surprised at a positive correlation between being a bad developer, and acting as if the world is populated entirely by English-speaking men.
Admin
It all came together. The code from this article drove the developer in the previous article to get rid of the "Mr". It's like a prequel, the Better Call Saul to the Breaking Bad.
Admin
@Remy Porter Yes, you are an array of biological cells (unless you've been an AI telling us stories all this time, but that I don't want to know).
Admin
Wellcome to the new paradigm: Array Oriented Programing.
Admin
More idiomatically written as my($foo, $bar) = @_;
Admin
"Meet the new boss/" (J at jsoftware.com) "Same as the old boss" (APL with ASCII and adverbs)
Admin
Correct, but there's not enough information to judge that.
Thinking of us all as arrays makes me think that it would be a really cool product to have a 3D voxel plot of your body as from an MRI.
Admin
Tobais, it was written for a monastery.
Admin
It will not work anyway, as there is a typo in the array name for the second parameter. $fullName = 'Mr.' . $names[1] . ' ' . $name[2];
=> name vs names.