I hereby claim:
- I am stianeikeland on github.
- I am stianeikeland (https://keybase.io/stianeikeland) on keybase.
- I have a public key whose fingerprint is 5D10 C9C5 6178 0BA2 0D29 6AE4 795E B458 3552 AF2F
To claim this, I am signing this object:
#!/bin/bash | |
sed -i "s/http:\/\/.*ubuntu.com\/ubuntu/http:\/\/old-releases.ubuntu.com\/ubuntu/g" /etc/apt/sources.list |
(require hy.contrib.loop) | |
(import [random [shuffle]]) | |
(def ranks (+ (range 2 11) [:a :k :q :j])) | |
(def suits [:h :c :d :s]) | |
;; OH MY IMPERATIVE GAAWD! | |
(def deck []) | |
(for [rank ranks | |
suit suits] |
(ns variants-playground.core | |
(:require [clojure.core.typed :as t :refer [cf defalias ann U Value Str HVec HMap]] | |
[clojure.core.match :refer [match]])) | |
(defmacro Variant [& lst] | |
`(U ~@(for [[tag & items] lst] | |
`(HVec [(Value ~tag) | |
(HMap :mandatory ~@items)])))) | |
(println (macroexpand '(Variant [:foo {:bar Str}]))) |
(ns ttt-gametree.core) | |
(def win-patterns [[0 1 2] ; 1st row | |
[3 4 5] ; 2nd row | |
[6 7 8] ; 3rd row | |
[0 4 8] ; diagonal | |
[2 4 6] ; diagonal | |
[0 3 6] ; 1st col | |
[1 4 7] ; 2nd col | |
[2 5 8]]) ; 3rd col |
(ns ticzip.core | |
(:require [clojure.zip :as z])) | |
(def game {:board (vec (repeat 9 nil)) | |
:player :x}) | |
(def next-player {:x :o, :o :x}) | |
(defn- free-tiles [{:keys [board]}] | |
(->> board |
I hereby claim:
To claim this, I am signing this object:
1 | |
| ||1 1 + | |
| | | ||& + | 2| | |
| | | | _|_ 5 | ]||1 | |
| | _|_ | 2 _|_ 1|] | |
_|_ | | | 5 5 < _|_ | |
7 & | | | | 1 & ] 4 | |
| " | | ____| |**____| [ 1 < | |
| |___ | |____ | | | |____| - | |
_| | | | | | | |11]-2 |
(ns musikk.core | |
(:require [serial-port :as serial] | |
[overtone.live :refer :all] | |
[overtone.inst.sampled-piano :refer :all])) | |
(def port (serial/open "/dev/tty.usbserial-A800F185" 57600)) | |
(defn chr->int [c] | |
(-> (char c) | |
(str) |
Write a function that returns true or false depending on whether its input integer is a leap year or not. | |
Begin on the top and work your way through the rules. | |
1. A leap year is divisible by 4. | |
Ex: 2001 is not a leap year. 1996 is a leap year. | |
2. .. but leap years are not divisible by 100. | |
Ex: 1900 is not a leap year. | |
3. .. unless it's also divisble by 400. |
# Install QEMU OSX port with ARM support | |
sudo port install qemu +target_arm | |
export QEMU=$(which qemu-system-arm) | |
# Dowload kernel and export location | |
curl -OL \ | |
https://github.com/dhruvvyas90/qemu-rpi-kernel/blob/master/kernel-qemu-4.1.7-jessie | |
export RPI_KERNEL=./kernel-qemu-4.1.7-jessie | |
# Download filesystem and export location |