📅  最后修改于: 2022-03-11 15:03:55.727000             🧑  作者: Mango
// Use a combination of Array.prototype.filter and Array.prototype.includes:
const filteredArray = array1.filter(value => array2.includes(value));