I hereby claim:
- I am franklinchen on github.
- I am franklinchen (https://keybase.io/franklinchen) on keybase.
- I have a public key ASDhVqCYgr6xkfxsfiM5OWYrkqFtO0Rc6P6wKgk8Mh8Xhwo
To claim this, I am signing this object:
use std::sync::{Arc, Mutex}; | |
use std::thread; | |
struct Toaster { | |
count: u32 | |
} | |
impl Toaster { | |
fn new() -> Toaster { | |
Toaster { count: 0 } |
require 'minitest/autorun' | |
# Traverse in preorder | |
def tree_traverse(tree, &block) | |
if tree.is_a? Array and tree.length > 0 | |
yield tree | |
tree.each {|t| tree_traverse(t, &block) } | |
end | |
end | |
import Test.HUnit | |
import qualified Data.List as List | |
import qualified Data.Ord as Ord | |
import Data.PSQueue as PSQueue | |
{- | |
For @BillLaboon | |
hey @franklinchen is there an easy way in Haskell to find out which element in a list is most common, e.g. [1,1,1,2,3] -> 1 ? |
Homebrew build logs for shibboleth-sp on macOS 10.12 | |
Build date: 2016-09-28 16:50:24 |
I hereby claim:
To claim this, I am signing this object:
#include <stdlib.h> | |
#include <stdio.h> | |
/* Single inheritance, treating Animal as abstract base class. */ | |
typedef struct Animal_vtable { | |
void (*eat)(void *); | |
void (*sound)(void *); | |
} Animal_vtable; | |
typedef struct Animal { |
-- | http://stackoverflow.com/questions/14259229/streaming-recursive-descent-of-a-directory-in-haskell/14261710#14261710 | |
-- | |
-- Updated to latest Pipes 4. | |
module Main where | |
import Pipes | |
import qualified Pipes.Prelude as P | |
import Control.Monad (forM_) | |
import System.Directory (doesDirectoryExist, getDirectoryContents) |