📜  php 数组公共元素 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:54:12.036000             🧑  作者: Mango

代码示例1
$a = array(1, 2, 3, 4);
$b = array(4, 5, 6, 7);
$c = array_intersect($a, $b);
if (count($c) > 0) {
    var_dump($c);
    //there is at least one equal value
}