[lib] small cleanup

master
Jacopo De Simoi 3 months ago
parent 3875ba2e76
commit e5dab89541
  1. 2
      lib/lib-advent.org

@ -46,7 +46,7 @@
#+begin_src emacs-lisp :results none
(defun advent/dot (a b)
"Return the dot product of the two vectors"
(-reduce #'+ (-map (lambda (x) (* (car x) (cdr x))) (-zip-pair a b))))
(-sum (-map (lambda (x) (* (car x) (cdr x))) (-zip-pair a b))))
(defun advent/neighbour (p dir)
"Returns the neighbour to P in the direction DIR"

Loading…
Cancel
Save