Sizeof() vs. Count()
Quick Tip: use sizeof() instead of count()
If you’re writing a PHP5 script, use the sizeof() function instead of count(). Although the manual says that sizeof() is a simple alias for count(), sizeof() is actually twice as fast, and can give a slight increase in performance, especially when used a lot.
In one of my scripts I saw performance increase by a whole second by using sizeof() instead of count(). I’m not sure why this is, especially since it’s officially an alias, but that’s just the way it is. Use it to your advantage!