rubik-cube-solver
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published

WIP

fork from cubejs

yarn add rubik-cube-solver

const cubeState = [
  "dbbburrfb", // front
  "rudrruddl", // right
  "flulfbddr", // up
  "llffdrubf", // down
  "rludlubrf", // left
  "lubfbfudl", // back
]
  .join("")
  .toUpperCase();

import { Cube } from 'rubik-cube-solver'
Cube.initSolver();
const cube = Cube.fromString(cubeState);
console.log(cube.solve());
// U F B R L U2 B2 U L2 F' U' F2 U2 L2 D L2 F2 U' R2 U2 L2 U'

Readme

Keywords

none

Package Sidebar

Install

npm i rubik-cube-solver

Weekly Downloads

2

Version

0.1.0

License

MIT

Unpacked Size

485 kB

Total Files

16

Last publish

Collaborators

  • ahaoboy