On Thu, 2011-04-28 at 22:12 -0400, Jim Giner wrote:
Obviously you have designed a search/decision mechanism that suits your
needs. The OP did not present a problem of such magnitude. He only asked
how to handle a decision process the most efficient way - with no mention of
higher goals
how many entries are you talking about, ie., how many conditions? Obviously
if you have more than 4-5 it's going to be easier to code up as a case
statement (?) rather than an if/else.
Never in all my days have I ever heard of using an array for such a
determination though.
(remainder
] Re: What's faster using if else or arrays?
how many entries are you talking about, ie., how many conditions?
Obviously
if you have more than 4-5 it's going to be easier to code up as a case
statement (?) rather than an if/else.
Never in all my days have I ever heard of using an array
Arrays - using a silly construct that probably still takes as much time to
evaluate machine-wise as anything else. And as far as readability goes, it
is even sillier. IMO.
(remainder deleted for readers' sakes :) )
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe,
On Thursday, April 28, 2011, Jim Giner wrote:
Arrays - using a silly construct that probably still takes as much
time to evaluate machine-wise as anything else. And as far as
readability goes, it is even sillier. IMO.
I don't know so much about that ...
I'll use a global array to
Obviously you have designed a search/decision mechanism that suits your
needs. The OP did not present a problem of such magnitude. He only asked
how to handle a decision process the most efficient way - with no mention of
higher goals such as yours.
didn't mean to offend anyone who has made
6 matches
Mail list logo