Compare commits

...

3 Commits

Author SHA1 Message Date
7ba21295ab version 0.1.1 2025-04-25 23:11:41 -04:00
2fd1a551be whitespace fix 2025-04-25 23:09:46 -04:00
78268d78da typo in docstring 2025-04-25 23:07:56 -04:00

View File

@@ -3,7 +3,7 @@
;; Copyright (C) Jonathan Lamothe
;; Author: Jonathan Lamothe <jonathan@jlamothe.net>
;; Package-Version: 0.1
;; Package-Version: 0.1.1
;; This file is not part of GNU Emacs.
@@ -35,13 +35,13 @@ MOVES represents the number of moves in the list."
(defun cube-build-scramble (moves)
"Generate a list of random moves for a 3x3 Rubik's cube
MOVES os the number of moves to generate. The algorithm will not
MOVES is the number of moves to generate. The algorithm will not
generate a sequence that moves the same face twice in a row."
(let (result last-face)
(while (> moves 0)
(setq last-face (cube-random-face last-face))
(push (cube-random-turn last-face) result)
(setq moves (1- moves )))
(setq moves (1- moves)))
result))
(defun cube-random-face (&optional last-face)