This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns berlin-clock.core | |
(:require | |
[sablono.core :as sab :include-macros true]) | |
(:require-macros | |
[devcards.core :as dc :refer [defcard deftest]])) | |
(enable-console-print!) | |
(defn get-clock-data | |
[hh mm ss] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns advocaat.core) | |
(def barrels [50 44 11 49 42 46 18 32 26 40 21 7 18 43 10 47 36 24 22 40]) | |
(def advocaat-amount 150) | |
;; imagine there are only two barrels: [50 44] | |
;; with these two barrels the complete list of all possible combinations is: | |
;; 50*0 + 44*0 => 0 | |
;; 50*0 + 44*1 => 44 | |
;; 50*1 + 44*0 => 50 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns gol.core | |
(:require | |
[reagent.core :as reagent] | |
[sablono.core :as sab :include-macros true]) | |
(:require-macros | |
[devcards.core :as dc :refer [defcard deftest defcard-rg]])) | |
(enable-console-print!) | |
(defn neighbours |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns chal209.unpack | |
(:require [clojure.string :refer [split]] | |
[clojure.set :refer [difference]])) | |
(def input1 | |
"6 1 1 | |
T H T L E D | |
P E N U R G | |
I G S D I S | |
Y G A W S I |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns dojo.core | |
(:require [clojure.math.combinatorics :as combo] | |
[clojure.set :as cs])) | |
(def board | |
[[0 1 0] | |
[0 0 0] | |
[1 0 0]]) | |
(def human-board |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns dojo3.core) | |
(def x {:size [10 10] | |
:rows [[] [1 1] [1] [2 1 1] [1 1 1] [1 2 1 1] [1] [1] [] []] | |
:cols [[] [1] [] [3] [1 1] [] [5] 1 [] [1 4 []]]}) | |
(def nono1 {:size [3 3] | |
:rows [[1] [3] [1]] | |
:cols [[1] [3] [1]]}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns dojo.core | |
(:require [clojure.string :as str])) | |
(defn parse-line | |
[l] | |
(->> (take 3 l) | |
(map #(partition 3 %)) | |
(apply map vector))) | |
(defn parse |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns myupsert.core | |
(require [datomic.api :as d])) | |
(def schema | |
[ | |
{:db/id #db/id [:db.part/db] | |
:db/ident :product/name | |
:db/valueType :db.type/string | |
:db/cardinality :db.cardinality/one | |
:db.install/_attribute :db.part/db} |