This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
(ns boids | |
(:use [enchilada :only [canvas ctx value-of canvas-size]] | |
[jayq.core :only [show]] | |
[monet.core :only [animation-frame]] | |
[monet.canvas :only [save restore | |
begin-path move-to line-to close-path | |
stroke stroke-style fill fill-rect fill-style | |
rotate translate]] | |
[boids.rules :only [step make-boid]]) | |
(:require [boids.vector :refer [heading]])) |
// A Roguelike turn system | |
// http://blog.deadreckoned.com/post/91616626322/havenguard-turn-system | |
// Requires a fast max-heap Priority Queue (I like this one: http://blog.mischel.com/2007/06/22/priority-queue-in-c/) | |
public class TurnEntity | |
{ | |
/// <summary> | |
/// The delegate to execute when the object's turn is executed. | |
/// </summary> | |
public Action TurnHandler { get; set; } |
Simply put, destructuring in Clojure is a way extract values from a datastructure and bind them to symbols, without having to explicitly traverse the datstructure. It allows for elegant and concise Clojure code.
FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.
public BBR(TargetInfo Target) | |
{ | |
//Config | |
//BuildConfiguration.RelativeEnginePath = /* ...*/; | |
//Debug | |
//---BuildConfiguration.bOmitPCDebugInfoInDevelopment = true /* d=false */; | |
//BuildConfiguration.bSupportEditAndContinue = false /* d=false */; | |
//BuildConfiguration.bDisableDebugInfoForGeneratedCode = true /* d=true */; | |
//BuildConfiguration.bAllowLTCG = false /* d=false */; |
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.Linq; | |
using System.Threading.Tasks; | |
// NOTE: Some of the classes here (namely the primitives like Vector2d and Rect2d) are not provided, | |
// but most should be fairly easy to implement yourself or replace with similar | |
// classes from other libraries. | |
// The exception is the Delaunay triangulation - that takes quite a bit more effort to implement. That said, |
Andrew Ng lecture, Stanford Graduate School of Business
High level, but totally worth watching.
https://www.youtube.com/watch?v=21EiKfQYZXc
I went looking for lectures from different sources and these are a great "from first principles" introduction. The newer cs231n lectures may have more relevant details, but I like Andrej Karpathy's