我有一个数组如下。
我想要的只是计算这个数组的顶部单元格;如在0,1,2,3,4和5中那样。对于这个数组,我的计数应为6。
我怎样才能做到这一点?
我试过
count(array)
和sizeof(array)
,但它提供了大量数据。
Array
(
[0] => Array
(
[0] => Array
(
[2011-11-18 00:00:00] => C
)
[1] => Array
(
[2011-11-18 00:00:00] => I
)
[2] => Array
(
[2011-11-18 00:00:00] => S
)
)
[1] => Array
(
[0] => Array
(
[2011-11-22 00:00:00] => C
)
[1] => Array
(
[2011-11-22 00:00:00] => S
)
)
[2] => Array
(
[0] => Array
(
[2011-11-22 00:00:00] => C
)
[1] => Array
(
[2011-11-22 00:00:00] => S
)
)
[3] => Array
(
[0] => Array
(
[2011-11-22 00:00:00] => C
)
[1] => Array
(
[2011-11-22 00:00:00] => S
)
)
[4] => Array
(
[0] => Array
(
[2011-11-22 00:00:00] => C
)
[1] => Array
(
[2011-11-22 00:00:00] => S
)
)
[5] => Array
(
[0] => Array
(
[2011-11-22 00:00:00] => C
)
[1] => Array
(
[2011-11-22 00:00:00] => S
)
)
)