Reference · Cube engine and views
movesNotationfunction
Moves as a person writes them, a space between each.
Import it
import { movesNotation } from "@johnmorrisdotca/kyuubu";
Definition
function movesNotation(moves: readonly CubeMove[], n: number): string
Parameters
| Name | Type | Description |
|---|---|---|
moves | readonly CubeMove[] | The turns, in their execution order. |
n | number | The cube’s side length. |
Returns
string
Moves as a person writes them, a space between each.
Examples
import { movesNotation, parseMoves } from "@johnmorrisdotca/kyuubu";
const moves = parseMoves("R U2", 3)!;
console.log(movesNotation(moves, 3));R U2What it prints (run when this page was built)