回傳偶數陣列:
function evenNumbers(array, number) {
return array.filter((el) => !(el & 1))
}
回傳奇數陣列:
function evenNumbers(array, number) {
return array.filter((el) => (el & 1))
}
...
回傳偶數陣列:
function evenNumbers(array, number) {
return array.filter((el) => !(el & 1))
}
回傳奇數陣列:
function evenNumbers(array, number) {
return array.filter((el) => (el & 1))
}
...