diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2025-08-11 12:05:08 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2025-08-11 12:05:08 +0200 |
| commit | 4544e08997a7af6a8defa47efae1e9ba5c2c30f6 (patch) | |
| tree | aa211e7f80429ca758573349e1866861469ec12b /python/examples/move.py | |
| parent | d25f23805c6d7128b508a359d47af136dd2fd0db (diff) | |
| download | nissy-core-4544e08997a7af6a8defa47efae1e9ba5c2c30f6.tar.gz nissy-core-4544e08997a7af6a8defa47efae1e9ba5c2c30f6.zip | |
Simplified name of Python module
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:") |
