PHP hangi ($ x> = 3) veya ($ x> 2) hızlıdır

0 Cevap php

Bir çok küçük tasarruf iki şekilde ama ofiste bir mini tartışma istenir ve bunu diğer geri bildirim almak istedim.

Daha etkilidir $ x tam sayı değerleri varsayarsak;

($x >= 3) 

veya

($x > 2)

edit

I have rolled back a wording change because one of the factors we discussed is that some believed >= to be easier to immediately read and felt that fveyaint values > 2 was pointless because you meant >= 3. This does not make the script faster but potentially more efficient in terms of maintaining it. (in before people explain how tiny a point this is)

0 Cevap