Skip to content

Instantly share code, notes, and snippets.


Norman Richards orb

View GitHub Profile
View zerosum.clj
(defn can-sum-to-zero
(can-zero nums #{}))
([nums can-sum-to]
(when (seq nums)
(let [num (first nums)]
(if (can-sum-to (- num))
(let [can-also-sum-to (map #(+ num %) can-sum-to)]
(recur (rest nums)
orb / sudoku.clj
Last active Apr 24, 2020 — forked from swannodette/gist:3217582
updated for the latest core.logic, with some minor tweaks for (I hope) clarity
View sudoku.clj
(ns sudoku
(:refer-clojure :exclude [==])
(:use [clojure.core.logic])
(:require [clojure.core.logic.fd :as fd]))
(defn init-board [vars puzzle]
(matche [vars puzzle]
([[] []]
View mtgox.html
<script src=""></script>
Bitcoin price is <b id="price">--</b>
$.get("", function(data) {
You can’t perform that action at this time.