Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am rojoangel on github.
  • I am keyrojobase (https://keybase.io/keyrojobase) on keybase.
  • I have a public key ASC25x9Iln24sfTn13IGXpbIvIrcj2bEA59HyWOi5yMaLQo

To claim this, I am signing this object:

@rojoangel
rojoangel / pigs.core-test.clj
Created October 17, 2017 19:56
BCN Clojure Community - Pigs Kata - 2017/10/17 Session
(ns pigs.core-test
(:require [clojure.test :refer :all]
[pigs.core :refer :all]))
(defn hold [player]
{:score (+ (:score player) (reduce + (:rolls player))) :rolls []})
(defn add-roll [player roll]
(update player :rolls conj roll))
@rojoangel
rojoangel / diamond-kata.md
Last active February 16, 2017 23:16
Diamond kata

Given a letter, print a diamond starting with ‘A’ with the supplied letter at the widest point.

For example: print-diamond ‘C’ prints

  A
 B B
C   C
 B B
  A
@rojoangel
rojoangel / 0_reuse_code.js
Created November 30, 2016 19:59
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
(ns kata-lights-out.core
(:require [reagent.core :as reagent :refer [atom]]))
;; -------------------------
;; Views
(def lights (atom [[1 1 1][1 1 1][1 1 1]]))
(defn neighbors [[x0 y0]]
(for [x (range 3)