mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-11-04 16:30:25 +08:00
12 lines
314 B
TypeScript
12 lines
314 B
TypeScript
// 判断两数组是否相同
|
|
export function judementSameArr(news: Array<string>, old: Array<string>) {
|
|
let count = 0;
|
|
const leng = old.length;
|
|
for (let i in old) {
|
|
for (let j in news) {
|
|
if (old[i] === news[j]) count++;
|
|
}
|
|
}
|
|
return count === leng ? true : false;
|
|
}
|