Skip to content

Instantly share code, notes, and snippets.

View davecremins's full-sized avatar

Dave Cremins davecremins

  • Intel
  • Limerick, Ireland
View GitHub Profile
@davecremins
davecremins / worker_pool.go
Created January 21, 2019 23:06
Very simple example of a worker pool pattern in Golang
package main
import (
"fmt"
"sync"
"time"
)
type Job chan int
type Pool chan Job
@davecremins
davecremins / 0_reuse_code.js
Created April 7, 2017 13:37
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@davecremins
davecremins / FizzBuzz
Created February 12, 2015 15:23
FizzBuzz Kata
for(var i = 1; i <= 100; i++)
if(i % 3 == 0 && i % 5 == 0)
console.log("FizzBuzz");
else if(i % 3 == 0)
console.log("Fizz");
else if(i % 5 == 0)
console.log("Buzz");
else
console.log(i);