当前位置:网站首页>PHP implementation deletes a value in a one-dimensional array
PHP implementation deletes a value in a one-dimensional array
2022-07-22 19:30:00 【Skipping Wang Xiaozhe】
Implementation process
array_merge(array_diff( Source array , To delete a parameter ));
<?php
$list = ['123','222','666','857','439'];
echo "<pre>";
print_r($list);
echo "<br />";
$temp = '857';
$arr = array_merge(array_diff($list, array($temp)));
echo "<pre>";
print_r($arr);
Realization effect
边栏推荐
- LeetCode 每日一题 2022/3/21-2022/3/27
- MIHA tour recruited a large number of new students, and the school enrollment was approved in advance on the last day!
- JS advanced - understanding of functions
- Programmer interview golden code interview question 01.02. determine whether it is character rearrangement
- What is "real time"
- Jackson 解析 JSON 详细教程
- Audio 3A processing practice makes your application more "pleasant"
- LeetCode 每日一题 2022/2/7-2022/2/13
- 融云漫话:通信中台
- Introduction to functions
猜你喜欢
Programmer interview golden code interview question 01.02. determine whether it is character rearrangement
Audio 3A processing practice makes your application more "pleasant"
Grafana panel - override field values
Terminal data protection of Internet communication security
Constructor
DOM introduction and query
MFC dialog program only runs a simple example of a single instance
融云 x 幸识: 专属 00 后的真我社交自留地(内含抽奖)
Idea construit le projet jfinal + génération automatique de code + test de fonctionnement de la base de données (trois méthodes)
MFC对话框程序只运行单个实例 的简单示例
随机推荐
Audio 3A processing practice makes your application more "pleasant"
Scenario practice | how to use rongyun super group to build a game community
Leetcode: 1179. Reformat department table
Centos7 installs MySQL 5.7 decompressed version & Navicat connection MySQL & firewall settings - the personal test is valid
Shell script debugging technology
IT外包服务业各领域的未来前景和趋势
工业路由器油田无线监控
融云首席科学家任杰:历练出人才,职场「经历>经验」
Grafana panel - modify visual text and background colors
场景实践 | 如何使用融云超级群构建游戏社区
Numpy finding the mean value of non-zero elements of matrix
Unity: material download
Jackson parsing JSON detailed tutorial
Unity: quick positioning camera
Help brand insight -- Analysis of consumers' emotional behavior
Leetcode: 596. Classes with more than 5 students
Leetcode daily question 2021/12/6-2021/12/12
Programmer interview golden code interview question 01.04. palindrome arrangement
JS advanced - understanding of functions
LeetCode 每日一题 2022/3/14-2022/3/20