SolveSummary型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
What a record comes to, worked out from its turns.
インポート
import type { SolveSummary } from "@johnmorrisdotca/kyuubu";
定義
type SolveSummary = {
size: number;
scramble: string;
moves: string;
start: string;
state: string;
solved: boolean;
count: number;
};
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
size | number | |
scramble | string | The scramble in notation. |
moves | string | The turns after it in notation. |
start | string | The cube once scrambled. |
state | string | The cube after every turn. |
solved | boolean | Whether it ended solved. |
count | number | The moves that count: every turn but those of the whole cube. |
例
import type { SolveSummary } from "@johnmorrisdotca/kyuubu";
import { parseMoves, summarize } from "@johnmorrisdotca/kyuubu";
const value: SolveSummary = summarize({ size: 3, scramble: parseMoves("R", 3)!, moves: parseMoves("R'", 3)! });
console.log(value.solved);true出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。