-
Cache-Oblivious Algorithms and Data Structures - Erik Demaine (One of the earliest papers in cache oblivious data structures and algorithms that introduces the cache oblivious model in detail and examines static and dynamic cache oblivious data structures built between 2000-2003)
-
Cache Oblivious B-Trees - Bender, Demaine, Farch-Colton (This paper presents two dynamic search trees attaining near-optimal performance on any hierarchical memory. One of the fundamental papers in the field where both search trees discussed match the optimal search bound of Θ(1+log (B+1)N) memory transfers)
-
Cache Oblivious Search Trees via Binary Trees of Small Height - Brodal, Fagerberg, Jacob (The data structure discussed in this paper works on the version of [2] but avoids the use o
"""Download sentry data. | |
usage: | |
python download_sentry_data.py <org>/<project> <api_key> | |
""" | |
import requests | |
import csv | |
import sys | |
if __name__ == '__main__': |
zsh users are advised to use the terminfo database as the most portable way to assign commands to particular keychords, but I haven't been able to find a database of which terminfo sigils correspond to which keys. Fortunately, I found enough information written in ancient Sumerian that I could translate it into something modern humans can comprehend.
Key Chord | Terminfo Name |
---|---|
Backspace | kbs |
Ctrl-Backspace | cub1 |
Insert | kich1 |
Shift-Insert | kIC |
Alt-Insert | kIC3 |
Shift-Alt-Insert | kIC4 |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE DataKinds #-} | |
{-# LANGUAGE KindSignatures #-} | |
{-# LANGUAGE TypeFamilies #-} | |
module Main where | |
import Data.Time (UTCTime, getCurrentTime) | |
data CircuitData = CircuitData {} |
While this gist has been shared and followed for years, I regret not giving more background. It was originally a gist for the engineering org I was in, not a "general suggestion" for any React app.
Typically I avoid folders altogether. Heck, I even avoid new files. If I can build an app with one 2000 line file I will. New files and folders are a pain.
{-# LANGUAGE DeriveDataTypeable #-} | |
{-# LANGUAGE GeneralizedNewtypeDeriving #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
module Rx.Actor | |
( GenericEvent, EventBus | |
, ActorBuilder, ActorM, ActorDef, Actor, RestartDirective(..), InitResult(..) | |
, SupervisorBuilder, SupervisorStrategy, SupervisorDef, Supervisor | |
-- ^ * Actor Builder API | |
, defActor, actorKey, preStart, postStop, preRestart, postRestart | |
, onError, desc, receive |
{-# LANGUAGE DeriveDataTypeable #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE MultiParamTypeClasses #-} | |
{-# LANGUAGE OverloadedStrings #-} | |
{-# LANGUAGE RecordWildCards #-} | |
{-# LANGUAGE StandaloneDeriving #-} | |
{-# LANGUAGE TypeFamilies #-} | |
{-# LANGUAGE GeneralizedNewtypeDeriving #-} | |
module Data.Haxl.Postgres.DataStoreExample |
-- in reply to http://www.reddit.com/r/haskell/comments/21mja6/make_lllegal_state_transitions_unrepresentable/ | |
-- | |
-- We implement a tiny language with three commands: Open, Close, and Get. | |
-- The first Get after an Open returns 1, the second Get returns 2, and so on. | |
-- | |
-- Get is only valid while the state is open, and | |
-- Open must always be matched by a Close. | |
-- We enforce both restrictions via the type system. | |
-- | |
-- There are two valid states: Opened and Closed. |
Find it here: https://github.com/bitemyapp/learnhaskell
:- use_module(library(clpfd)). | |
peano(N,z) :- N #= 0. | |
peano(N,s(PDec)) :- | |
N #> 0, | |
N - 1 #= NDec, | |
peano(NDec, PDec). | |
% ?- peano(4, Q). | |
% Q = s(s(s(s(z)))) ; |