diff options
Diffstat (limited to '')
| -rw-r--r-- | python/examples/move.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/python/examples/move.py b/python/examples/move.py index 9c7a756..0ed879b 100644 --- a/python/examples/move.py +++ b/python/examples/move.py | |||
| @@ -1,10 +1,13 @@ | |||
| 1 | # Small example of nissy_python_module usage | 1 | # Small example of nissy Python module usage |
| 2 | # See the solve.py example for more details on how this works | 2 | # See the solve.py example for more details on how this works |
| 3 | 3 | ||
| 4 | import os, sys | 4 | import os, sys |
| 5 | 5 | ||
| 6 | # Assume we are eithe rin the top-level directory of the nissy-core repo, | ||
| 7 | # or in the python subdirectory | ||
| 6 | sys.path.append(os.getcwd()) | 8 | sys.path.append(os.getcwd()) |
| 7 | import nissy_python_module as nissy | 9 | sys.path.append(os.getcwd() + os.path.sep + "python") |
| 10 | import nissy | ||
| 8 | 11 | ||
| 9 | cube = nissy.applymoves(nissy.solved_cube, "R' U' F"); | 12 | cube = nissy.applymoves(nissy.solved_cube, "R' U' F"); |
| 10 | print("Cube after the moves R' U' F:") | 13 | print("Cube after the moves R' U' F:") |
