orthogonalHint関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
Gives a clue-only deduction; flags remain notes and cannot influence the result.
インポート
import { orthogonalHint } from "@johnmorrisdotca/jirai/orthogonal";
ほかのエクスポート元: @johnmorrisdotca/jirai
定義
function orthogonalHint(game: Game): Deduction
引数
| 名前 | 型 | 説明 |
|---|---|---|
game | Game | The native game, or answer-free VisibleGame required by the signature. |
戻り値
Deduction
Gives a clue-only deduction; flags remain notes and cannot influence the result.
例
import type { OrthogonalSettings } from "@johnmorrisdotca/jirai/orthogonal";
import { play } from "@johnmorrisdotca/jirai";
import { newOrthogonalGame, orthogonalHint } from "@johnmorrisdotca/jirai/orthogonal";
const orthogonalSettings: OrthogonalSettings={width:3,height:3,mines:1,noGuess:false,opening:"clear",seed:42};
const orthogonalGame=play(newOrthogonalGame(orthogonalSettings),{kind:"reveal",cell:0});
console.log(orthogonalHint(orthogonalGame));{
safe: [ 5, 6, 7, 8 ],
mines: [],
reason: 'total',
sources: [ 1 ],
contradiction: false
}出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。