Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re^5: Useless use of string in return statement

by Anonymous Monk
on Apr 13, 2021 at 16:11 UTC ( #11131200=note: print w/replies, xml ) Need Help??


in reply to Re^4: Useless use of string in return statement
in thread Useless use of string in return statement

$a and $b should not be understood as stand-ins for "anything"

True. I very consciously chose the scalars $a and $b. In fact, I had originally started to write return A ? A : B; but realized that that would not be sufficient, nor would it be necessary for the point (i.e. the OP's problem).

Replies are listed 'Best First'.
Re^6: Useless use of string in return statement
by haukex (Bishop) on Apr 13, 2021 at 16:19 UTC
    nor would it be necessary for the point (i.e. the OP's problem).

    True, but if you're going to be nitpicky and mention tied variables, then better go all the way ;-)

      If we're going to get that nick-picky, then I'll point out that $a and $b cannot be stand-ins for "anything" ... since they are scalars. So you were jousting at stars that never felt a wound.

        I'll point out that $a and $b cannot be stand-ins for "anything"

        I chose my wording "should not be understood" carefully: it's a clarification for any reader for whom the distinction between $a || $b and @a || @b may be unclear. And maybe you missed the smiley at the end of my post above.

        So you were jousting at stars [concern-trolling] that never felt a wound.

        Says the anonymous poster making insults... he who lives in a glass house.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11131200]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (4)
As of 2021-05-07 10:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Perl 7 will be out ...





    Results (91 votes). Check out past polls.

    Notices?