[p2] Initial boilerplate

master
Jacopo De Simoi 4 months ago
parent d41fcb3545
commit 3301862db1
  1. 17
      p2/p2.org

@ -0,0 +1,17 @@
#+title: Solution to p2
First load the data as a list of cons cells (stsrt . end)
#+begin_src emacs-lisp :results none
(with-temp-buffer
(insert-file-contents "input-test")
(advent/replace-multiple-regex-buffer
'(("," . "\n")
("-" . " . ")
("^" . "(")
("$" . ")")))
(goto-char (point-min))
(insert "(setq data '(")
(goto-char (point-max))
(insert "))")
(eval-buffer))
#+end_src
Loading…
Cancel
Save