Skip to content

Instantly share code, notes, and snippets.

View gigasquid's full-sized avatar

Carin Meier gigasquid

View GitHub Profile

It's hard to know which is more dystopian: the idea that your every move is being studied by occasionally malign figures of an anonymous goverment authority, or that everything you've done in the public sphere for years now been secretly recorded for no particular reason, by people who would rather be doing almost anything else, in an apotheosis of archival bureaucracy that you yourself pay for through tax.

(ns conversations.datomic
(require [datomic.api :as d]))
;; Hi Datomic! I have been hearing good things about you. I would
;; like to talk to you and get to know you is that alright?
;; Sure - I would be happy to have a conversation with you.
(def uri "datomic:mem://first-conversation")
(d/create-database uri)
@gigasquid
gigasquid / intsaparse-into.clj
Last active August 29, 2015 14:20
Instaparse Introduction
(ns coollang.parser
(:require [instaparse.core :as insta]))
;;; Steps to building a language
;;;; Step 1 parse an integer
(def parser
(insta/parser
"number = #'[0-9]+'"))
### Keybase proof
I hereby claim:
* I am gigasquid on github.
* I am carinmeier (https://keybase.io/carinmeier) on keybase.
* I have a public key whose fingerprint is D721 DD0A CB75 F910 8285 B3C5 1B77 54F9 A790 9812
To claim this, I am signing this object:
@gigasquid
gigasquid / fizzbuzz.clj
Created November 7, 2014 23:36
FizzBuzz without Conditionals
(defn fizzbuzz [n]
(let [all-nums (range 0 n)
folder (fn [fb-str p-num fb-coll]
(mapcat (fn [x] (cons fb-str (rest x)))
(partition-all p-num fb-coll)))
fizz (folder "fizz" 3 all-nums)
buzz (folder "buzz" 5 fizz)
fizzbuzz (folder "fizzbuzz" 15 buzz)]
fizzbuzz))
@gigasquid
gigasquid / gist:6458227
Last active December 22, 2015 10:19
The Love Song of J. Object Prufrock
I have heard the monads singing, each to each.
I do not think that they will sing to me.
I have seen them riding onwards on the lambdas
Lifting the functions of data blown back.
When the functors blow the categories white and black.
@gigasquid
gigasquid / tech_cincy.txt
Last active December 20, 2015 01:09
Thoughts about greater visibility with tech in Cincinnati
(The following is a result of a chat that Chris Moore and I had
at the last Gaslight Coffee day)
Here in our lovely city of Cincinnati we have many cool things happening in the tech scene.
We have
- lively user groups
- special events - like NodeCopter coming up http://cinycopter.com
- Hardware hacking projects like http://opengarages.org/ at Hive13
- Ignite
- Maker Faire http://cincinnatimakerfaire.com/
@gigasquid
gigasquid / brackets.clj
Created June 5, 2013 13:23
Clojure and Coffee with Instaparse
(ns brackets.core-test
(:use clojure.test
brackets.core
instaparse.core))
(def my-parser
(parser
"S = func-apply | vector | integer
integer = #'[0-9]+'
<space> = <' '>
@gigasquid
gigasquid / countdown.hs
Created February 13, 2013 03:06
Nasa Countdown in Haskell with HUnit - from Cincy FP
module Main where
import Test.HUnit
-- nasa :: Int -> [Int] -- | []
nasa n = reverse [0..n]
-- | n <= 0 = [0]
-- | otherwise = n : (nasa $ n - 1)
-- test1 :: Test
@gigasquid
gigasquid / fizzbuzz.hs
Created February 13, 2013 03:03
Fizzbuzz with HUnit and Quick Check - in progress from Cincy FP
-- Example.hs -- Examples from HUnit user's guide
--
-- For more examples, check out the tests directory. It contains unit tests
-- for HUnit.
module Main where
import Test.HUnit
import Test.QuickCheck