Skip to content

Instantly share code, notes, and snippets.

@jkhulme
jkhulme / gist:78affdb5fff5a1c5b114
Last active August 29, 2015 14:02
Step by step process of setting up my mac

#Step by Step for how I set up my mac

This assumes a fresh install of Yosemite

##Developer Stuff

First thing, install command line tools

xcode-select --install
@jkhulme
jkhulme / gist:9652923
Last active August 29, 2015 13:57
Bolognese Recipe
Ragù (Bolognese sauce)
From Marcella Hazan's The Classic Italian Cookbook
A properly made ragu clinging to the folds of home-made noodles is one of the most satisfying experiences accessible to the sense
of taste. It is no doubt one of the great attractions of the enchanting city of Bologna, and the Bolognese claim one cannot make a
true ragù anywhere else. This may be so, but with a little care we can come very close to it. There are three essential points
you must remember in order to make a successful ragù. 1)The meat must be sautéed just barely long enough to lose its raw colour.
It must not be brown or it will lose delicacy.
2) It must be cooked in milk before the tomatoes are added. This keeps the meat creamier and sweeter tasting.
@jkhulme
jkhulme / gist:9123600
Created February 20, 2014 21:29
Method sink, rather than initialising to None
class Sink:
def __init__(self):
pass
def __getattr__(self, name):
def _missing(*args, **kwargs):
pass
return _missing
#!/usr/bin/env python
from __future__ import braces
class ExamBoard(object):
def submit(self, work):
work_is_passing_grade = len([work]) > 0
return work_is_passing_grade
#!/usr/bin/env python
class ExamBoard(object):
def submit(self, work):
work_is_passing_grade = len([work]) > 0
return work_is_passing_grade
#!/usr/bin/env python
class Society(object):
def __init__(self, name):
self.name = name
self.members = []
def add_member(self, name, matric_number):