Refactor
This commit is contained in:
parent
747099821f
commit
f55cb79a70
|
@ -349,11 +349,10 @@ function think() {
|
||||||
for (const p of cans) {
|
for (const p of cans) {
|
||||||
if (isBotTurn) {
|
if (isBotTurn) {
|
||||||
alpha = Math.max(alpha, dive2(p, alpha, beta, depth + 1));
|
alpha = Math.max(alpha, dive2(p, alpha, beta, depth + 1));
|
||||||
if (alpha >= beta) break;
|
|
||||||
} else {
|
} else {
|
||||||
beta = Math.min(beta, dive2(p, alpha, beta, depth + 1));
|
beta = Math.min(beta, dive2(p, alpha, beta, depth + 1));
|
||||||
if (alpha >= beta) break;
|
|
||||||
}
|
}
|
||||||
|
if (alpha >= beta) break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 巻き戻し
|
// 巻き戻し
|
||||||
|
|
Loading…
Reference in New Issue