The result of the count() function in the above example, will be 4.
PHP sizeof() Function
The result of the sizeof() function in the above example, will be 4.
In almost any useful or complex php application, there will likely be a reason to count an array. Since an array is simply a list of items, words, etc., how could this function be useful to you as a php programmer or web developer?
When it comes to earning money, or creating a useful php application in the competitive marketplace, “why” you code, is just as important, as “how” you code.