Skip to content

Instantly share code, notes, and snippets.

View jordanorelli's full-sized avatar
🎴

Jordan Orelli jordanorelli

🎴
View GitHub Profile
import themidibus.*;
MidiBus myBus;
int y = 0;
int vel = 0;
void setup() {
size(1024, 768);
background(0);
myBus = new MidiBus(this, 0, -1);
@jordanorelli
jordanorelli / dol_system.go
Created July 14, 2013 18:32
simple DOL-System
package main
import (
"bytes"
"fmt"
)
type ProductionSet map[rune]string
type Alphabet map[rune]bool
@jordanorelli
jordanorelli / main.pde
Created July 15, 2013 03:32
quadratic koch island in Processing, as in The Algorithmic Beauty of Plants.
void setup() {
size(500, 500);
smooth();
background(255);
stroke(0);
strokeWeight(1);
HashMap productions = new HashMap();
productions.put('F', "F-F+F+FF-F-F+F");
String axiom = "F-F-F-F";
import java.awt.AWTException;
import java.awt.Robot;
Robot robot;
float b, x;
float tspeed;
PVector middle;
boolean left, right, backward, forward;
boolean SOOPASPEED;
int fullspeed = 6;
import java.awt.AWTException;
import java.awt.Robot;
Robot robot;
float turn;
boolean SOOPASPEED;
int fullspeed = 6;
int regspeed = 1;
PVector pos;
PVector velocity = new PVector(0, 0); // initially, you're not moving.
package main
import (
"fmt"
"math/rand"
"time"
)
type connection struct {
name string
@jordanorelli
jordanorelli / rpn.go
Last active December 20, 2015 16:59
stack-based rpn accumulator
package main
import (
"bufio"
"errors"
"fmt"
"os"
"strconv"
"strings"
)
package main
import (
"database/sql"
"encoding/json"
"html/template"
"log"
"math/rand"
"net/http"
"runtime"
diff --git a/go/src/hello/hello.go b/go/src/hello/hello.go
index 5f54709..b843e19 100644
--- a/go/src/hello/hello.go
+++ b/go/src/hello/hello.go
@@ -10,6 +10,7 @@ import (
"runtime"
"sort"
"strconv"
+ "sync"
package main
import (
"flag"
"fmt"
"io"
"log"
"net/http"
"os"