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
(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) |
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
(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)) |
I hereby claim:
To claim this, I am signing this object: