php count the number of strings after exploded

前端 未结 5 1092

Here is my code

$key) {
$i >0;
    echo $i.\' \'.$key .         


        
5条回答
  •  太阳男子
    2021-01-04 18:53

    programmers always count from 0, it's good practice, but if you really need to do this simply declare the $i variable as 1 before the fooreach loop

提交回复
热议问题