if (isMonday) { a = 1; } else if (isSaturday || isSunday) { a = 0; } else { a = -1 } ... ... https://jsperf.com/switch-c... XD 雖然沒有三元運算式的測試.
確定! 回上一頁