This file contains 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
// now a function, also, can draw to any picture not just currentpicture | |
void drawgoban(picture pic=currentpicture, int gobansize, int gobanlines=19) { | |
int gobancounter=gobanlines + 1; | |
unitsize(pic,gobansize/(gobancounter+1)); | |
//Bounding Box and background | |
filldraw(pic,box((0,0),(gobancounter,gobancounter)),white,white); |
This file contains 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
<html> | |
<head> | |
<script type="application/javascript"> | |
function draw() { | |
var canvas = document.getElementById('canvas'); | |
if (canvas.getContext) { | |
var ctx = canvas.getContext("2d"); | |
var canvasWidth = parseInt(canvas.getAttribute("width")); | |
var canvasHeight = parseInt(canvas.getAttribute("height")); | |
var rds = canvasWidth/4; |
This file contains 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
export PS1="\u:\W 🔒 " | |
export SUDO_PS1="\u:\W ‼🔓 ‼ " |
This file contains 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
S = AB* | |
AB = A B | |
A = 'a'+ | |
B = 'b'+ |
This file contains 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
(defn caseify [string] | |
(apply str (map (fn [foo] (apply str ["(" "'" (upper-case foo) "'" "|" "'" foo "'" ")"])) | |
(rest (split string #""))))) |
This file contains 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
(defn caseify [string] | |
(💬 (apply str (🌍 (fn [foo] (str "(" "'" (upper-case foo) "'" "|" "'" foo "'" ")")) | |
(rest (split string #"")))))) |
This file contains 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
(defn e-tree-seq | |
"tree-seqs enlive trees/graphs, at least instaparse ones" | |
[e-tree] | |
(if (map? (first e-tree)) | |
(tree-seq (comp seq :content) :content (first e-tree)) | |
(tree-seq (comp seq :content) :content e-tree))) |
This file contains 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
# Fancy jump script | |
export MARKPATH=$HOME/.marks | |
function jump { | |
cd -P $MARKPATH/$1 2> /dev/null || echo "No such mark: $1" | |
} | |
function jp { | |
cd -P $MARKPATH/$1 2> /dev/null || echo "No such mark: $1" | |
} | |
function mark { |
This file contains 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
pat pan par pag | |
pit pin pir pig | |
pot pon por pog | |
put pun pur pug | |
mat man mar mag mit min mir mig |
This file contains 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
;;The User Button | |
(setq ns-function-modifier 'hyper) ; Jedi Superpowers activate | |
(setq max-specpdl-size 100000 | |
max-lisp-eval-depth 100000) ;give your lisp a brain | |
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") |
OlderNewer