MyGit

adrianliaw/PyCuber

Fork: 47 Star: 199 (更新于 2024-12-17 00:59:45)

license: MIT

Language: Python .

Rubik's Cube solver in Python

最后发布版本: v0.2.0 ( 2015-06-07 09:52:55)

GitHub网址

PyCuber

pip install pycuber

PyCuber is a Rubik's Cube package in Python 2/3

The cube can be revealed as expanded view in the terminal, so it's easy to visualise the cube, just inside the terminal. (Not tested on Windows)


import pycuber as pc

# Create a Cube object
mycube = pc.Cube()

# Do something at the cube.
mycube("R U R' U'")

print(mycube)

alt tag

We also provided some useful tools to deal with Rubik's Cube formulae.


import pycuber as pc

# Create a Formula object
my_formula = pc.Formula("R U R' U' R' F R2 U' R' U' R U R' F'")

# Reversing a Formula
my_formula.reverse()
print(my_formula)

# Mirroring a Formula object
my_formula.mirror("LR")
print(my_formula)

F R U' R' U R U R2 F' R U R U' R'
F' L' U L U' L' U' L2 F L' U' L' U L

I'll add some documentations later.

最近版本更新:(数据更新于 2024-09-03 05:00:40)

2015-06-07 09:52:55 v0.2.0

2014-11-21 16:45:01 v0.1.0

主题(topics):

cube, rubik-cube

adrianliaw/PyCuber同语言 Python最近更新仓库

2024-12-22 18:18:34 LeslieLeung/heimdallr

2024-12-22 09:03:32 ultralytics/ultralytics

2024-12-21 13:26:40 notepad-plus-plus/nppPluginList

2024-12-21 11:42:53 XiaoMi/ha_xiaomi_home

2024-12-21 04:33:22 comfyanonymous/ComfyUI

2024-12-20 18:47:56 home-assistant/core