Skip to content

Instantly share code, notes, and snippets.

@antoniogarrote
Created November 1, 2010 08:34
Show Gist options
  • Save antoniogarrote/657830 to your computer and use it in GitHub Desktop.
Save antoniogarrote/657830 to your computer and use it in GitHub Desktop.
(def *reg-nos* [16738 17288 18162 18776 18868 19116 19223 19505])
(def *df-url* "http://www.mapa.es/agricultura/pags/fitos/registro/sustancias/pdf/")
(def *pdfs* (map #(list (str *df-url* % ".pdf") %) *reg-nos*))
(time
(doseq [[pdf id] *pdfs*]
(spit (str id ".pdf") (slurp (java.net.URL. pdf)))))
;; Elapsed time 667.91 msecs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment