Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re: Ternary vs. Sort vs. Max

by BrowserUk (Pope)
on Aug 10, 2015 at 10:38 UTC ( #1138006=note: print w/replies, xml ) Need Help??

in reply to Ternary vs. Sort vs. Max

That sort construction is (IMO) far more obscure and obfuscate than the ternary.

As for List::Util::max(); if I need to find the max() of a bunch (more than two) things, I use it, but -- just as my wife doesn't break out her food processor to slice a tomato for a sandwich -- for two items, the ternary construct is simple, efficient (and to me; clear). Perfect for the task at hand.

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
In the absence of evidence, opinion is indistinguishable from prejudice.
I'm with torvalds on this Agile (and TDD) debunked I told'em LLVM was the way to go. But did they listen!

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2021-01-17 10:25 GMT
Find Nodes?
    Voting Booth?