[p5] part 1

master
Jacopo De Simoi 3 months ago
parent 796ff1a244
commit 507d4751a7
  1. 13
      p5/p5.org

@ -15,3 +15,16 @@ First load the data as a list of cons cells (start . end)
(eval-buffer))
#+end_src
#+begin_src emacs-lisp
(length
(-filter (lambda (id)
(--any (and (>= id (car it))
(<= id (cdr it)))
#+end_src
#+begin_src emacs-lisp
(setq sorted-ranges (--sort (< (car it) (car other)) ranges))
#+end_src
#+RESULTS:
: 744

Loading…
Cancel
Save