- The best tutorials are in the introductory books. See below.
- Getting Started with Clojure - A detailed tutorial on getting a modern (as of Jan 2013) Clojure workflow going.
- Emacs Live is a nice development environment based on Emacs.
- Understanding The Clojure Development Ecosystem
- Clojure Docs Site is a community-driven doc site with good tutorials, and reference material going somewhat deeper than individual API docs.
- Functional Programming for the Rest of Us is a classic introduction to functional thinking
- [A comprehensive article on namespaces and different ways of requiring them](http://blog.8thlight.com/colin-jones/2010/12/05/clojure-libs-and-namespaces-require-use-import-and-ns.
#!/usr/bin/env python | |
# encoding: utf-8 | |
import Image | |
import sys | |
import os | |
def main(): | |
path = "where-images-may-live" | |
import pygame | |
from pygame import surfarray | |
from pygame.locals import * | |
import sys, numpy as n | |
# Based on code from D. Shiffman (http://processing.org/learning/topics/mandelbrot.html) | |
# and P. Bourke (http://paulbourke.net/fractals/mandelbrot/) | |
def main(): |
''' | |
Created on Aug 10, 2012 | |
@author: spellrh | |
''' | |
import numpy as n | |
import pygame | |
from pygame.locals import * | |
from pygame import surfarray |
import maya.cmds as mc | |
import math | |
import random | |
def clr(): | |
""" | |
helper function that will clear all primitives from the screen | |
""" | |
mc.select(all=True) | |
mc.delete() |
import maya.cmds as mc | |
import math | |
import random | |
def uniformRandom(): | |
for i in range(100): | |
mc.polyCube() | |
x = random.uniform(-1,1) * 5 # these are the same | |
z = random.random() * 10 - 5 # this does the same as above | |
mc.move(x,0.,z) |
''' | |
Code from InventWithPython.com - "stop using print for debugging" | |
http://inventwithpython.com/blog/2012/04/06/stop-using-print-for-debugging-a-5-minute-quickstart-guide-to-pythons-logging-module/ | |
''' | |
# Print log to the screen | |
import logging | |
logging.basicConfig(level=logging.DEBUG, format='%(asctime)s - %(levelname)s - %(message)s') |
void setup() { | |
size(600, 600); | |
background(0); | |
smooth(); | |
translate(300, 300); | |
for (float i=0; i<360; i += 0.5) { // bump by .5 for ellipses, 1 for others | |
pushMatrix(); | |
rotate(radians(i)); | |
translate(0, 200); | |
rotate(radians(i*3)); |
This is required to build some of the pacakages that Homebrew will install. Get the command line tools for Apple Developer. This is included with XCode, but I don't want the heavy XCode download so I opt for the lighter Command Line Tools.
A write-up on the use of this step from the project authors. Thoughtbot has a useful script for setting up a Mac development environment. If you want to use their script as is then you can navigate to their Git repository and follow the instructions on the ReadMe. If you want to customize the install script then fork their repository and customize as needed. Their code is very well commented and you can use their code as a template for your packages. sit back and chill, this'll take a minute (might I suggest some: Keziah Jones ??)
// from http://ntt.cc/2008/02/10/4-ways-to-dynamically-load-external-javascriptwith-source.html | |
// TODO: will make mddn242 specific examples | |
// you need to put an escape character before the closing </script> tag, like this: <\/script> | |
1. use document write | |
<script language="javascript"> | |
document.write("<script src='other.js'><\/script>"); | |
</script> |