摘要: 1、判断数组 b 的所有元素是否都在数组 a 中 const a = [1, 2, 3, 4, 5]; const b = [2, 4]; const allElementsInA = b.every(element => a.includes(element)); console.log(allE 阅读全文
posted @ 2023-11-01 16:38 iwen1992 阅读(1) 评论(0) 推荐(0) 编辑