Re: Variable as an index

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Anthony Gentile wrote:
True, it might mean the very slightest in milliseconds...depending on what you're doing/hardware.

Connecting to a db will (probably) take longer than most of those differences, let alone running a query & processing the results.

Ternaries that make a lot of people feel awesome because a lot is being accomplished in one line are also more opcodes than their if-else statement equivalents...and often times can be more confusing to future maintainers of the code.

I dislike ternaries for their over-use - I've seen nested ternaries and it's taken me 10 mins to read the code.. *shudder*.

--
Postgresql & php tutorials
http://www.designmagick.com/


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux