Skip to content

Instantly share code, notes, and snippets.

View aergus's full-sized avatar

Aras Ergus aergus

View GitHub Profile
@aergus
aergus / keybase.md
Last active March 9, 2017 11:00
Keybase Proof

Keybase proof

I hereby claim:

  • I am aergus on github.
  • I am aergus (https://keybase.io/aergus) on keybase.
  • I have a public key whose fingerprint is 721E 257F 77DF 2F12 1205 D1F2 EA5D 3393 3881 EB12

To claim this, I am signing this object:

DUM 34
LDF 38
LDF 1082
LDF 1084
LDF 1086
LDF 1088
LDF 1090
LDF 1092
LDF 1094
LDF 1096
@aergus
aergus / weirddo.lisp
Last active August 29, 2015 14:04
LambdaLisp do block which may be the cause of an error
{ cur <- (CAR stack);
pr <- (_handleDirR map cur 0);
newStack <- (IF (== -1 (CAR pr))
(CDR stack)
(: (_applyDir cur (CAR pr)) stack)
);
(IF (== counter 0) newStack
(_lambdaDFSR target newStack (CDR pr) (+ counter 1))
)
}
@aergus
aergus / dofail.lisp
Last active August 29, 2015 14:04
LamdaLisp (non-)example for failure of do notation
main =
(_mapSearchR 0 ([] ([] 0) ([] 1)) 0)
-- _mapSearchR :: Eq a => a -> [[a]] -> Int -> (Int, Int)
-- after removing the commented brackets this works too:
_mapSearchR =
(\ x xss k ->
(IF (NIL xss)
(: -1 -1)
-- (