Skip to content

Instantly share code, notes, and snippets.

@supki
supki / GameDef.scala
Created November 2, 2012 14:29
Functional programming course at Coursera week 7.
package streams
import common._
trait GameDef {
case class Pos(x: Int, y: Int) {
def dx(d: Int) = copy(x = x + d, y)
def dy(d: Int) = copy(x, y = y + d)
@UniIsland
UniIsland / SimpleHTTPServerWithUpload.py
Created August 14, 2012 04:01
Simple Python Http Server with Upload
#!/usr/bin/env python
"""Simple HTTP Server With Upload.
This module builds on BaseHTTPServer by implementing the standard GET
and HEAD requests in a fairly straightforward manner.
"""