Skip to content

Instantly share code, notes, and snippets.

@walm
Created September 10, 2011 20:03
Show Gist options
  • Save walm/1208711 to your computer and use it in GitHub Desktop.
Save walm/1208711 to your computer and use it in GitHub Desktop.
class Beans
from : [ 'Central America', 'South America', 'East Africa' ]
brand : 'Gevalia'
name : 'Ebony'
class Coffee extends Beans
sugar : no
milk : no
people = [ 'Andreas', 'Sofia' ]
serve = for person in people
cup = new Coffee
cup.sugar = yes unless person is 'Sofia'
cup.milk = yes if person is 'Sofia'
cup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment