Home  >  Article  >  Backend Development  >  数组剔除某m个元素后,重新整理key,从0~n,逐1递增

数组剔除某m个元素后,重新整理key,从0~n,逐1递增

WBOY
WBOYOriginal
2016-06-13 11:18:01956browse

数组删除某m个元素后,重新整理key,从0~n,逐1递增
数组删除某n个元素后,重新整理key,从0~n,逐1递增
而不是key数值不连续出现中断
要怎么做?


------解决方案--------------------
array_values
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn