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 cuber.core) | |
| ;; octal numbers: | |
| (def start [0 1 2 3 4 5 6 7]) | |
| (def end [4 2 4 2 4 2 4 2]) | |
| (defn modding [f] | |
| ;; identity | |
| (fn [x] (mod (f x) 8))) |
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
| ;; Declare namespace | |
| (ns harmonium.sock-problem2 | |
| (:require [clojure.pprint :refer [pprint]])) | |
| ;; ============ Starting here are some functions =========== | |
| ;; ============ for formatting output; feel free =========== | |
| ;; ============ to ignore. =========== | |
| (defn to-percent [total n] |
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
| colorscheme morning | |
| if has("gui_macvim") | |
| let macvim_hig_shift_movement = 1 | |
| endif | |
| set nocompatible | |
| source $VIMRUNTIME/vimrc_example.vim | |
| source $VIMRUNTIME/mswin.vim |
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 precip | |
| (:use [clojure.math.numeric-tower :only (expt)])) | |
| (defn average [l] | |
| (float (/ | |
| (reduce + l) | |
| (count l)))) | |
| (defn variance [l] | |
| (let [vmean (average l)] |
NewerOlder