Skip to content

Instantly share code, notes, and snippets.

View wtaysom's full-sized avatar

William Taysom wtaysom

  • High Stakes Engineering
  • Taiwan
  • X @wtaysom
View GitHub Profile
@wtaysom
wtaysom / bel-eve-vr.md
Last active January 24, 2024 03:25
A Review of Paul Graham's Bel, Chris Granger's Eve, and a Silly VR Rant

Hello Friends,

This elf begging to climb onto the web for Christmas began as a personal email, a review of Paul Graham's little Lisp Bel. He sprouted arms, legs, and in gingerstyle ran away. Arms for symbols, legs for conses: these primitives are the mark a Lisp — even more so than the parenthesis. What do we get when we remove these foundation stones: naming and pairing?

No pairs. No cons. No structure. Unordered. Chaos. Eve, a beautifully incomplete aspect oriented triple store. No need for legs when you can effortlessly transport to your destination. Lazy. Pure. Here and now, a retrospective.

No symbols. No names. No variables. Combinators. Forth. No need for arms when you can effortlessly push and pop your stack. No words. A world without words. Virtual worlds. Virtual reality. Space. Time. Motion. Action. Kinetic Programming, a proposal.

I apologize in advance. Checking my pocketwatch, I see I haven't t

@wtaysom
wtaysom / where_is.rb
Created September 23, 2011 08:57
A little Ruby module for finding the source location where class and methods are defined.
module Where
class <<self
attr_accessor :editor
def is_proc(proc)
source_location(proc)
end
def is_method(klass, method_name)
source_location(klass.method(method_name))
@wtaysom
wtaysom / .pryrc.rb
Created December 19, 2011 10:51
William's .pryrc
## _why inspired citizen428 delivered MethodFinder.
require_relative 'methodfinder_what'
## Pry Config
Pry.config.pager = false
Pry.config.editor = "mate -w"
Pry.config.prompt = [proc{"? "}, proc{"| "}]
@wtaysom
wtaysom / keybase.md
Created September 20, 2017 07:02
Keybase Proof

Keybase proof

I hereby claim:

  • I am wtaysom on github.
  • I am wtaysom (https://keybase.io/wtaysom) on keybase.
  • I have a public key ASDhhgHIa18lWpOtSZzCPBm4S0H0Hl8_Ajn3mJAhNd6l9wo

To claim this, I am signing this object:

@wtaysom
wtaysom / nim.clj
Created September 4, 2012 02:54
Nim Minimal Viable Snippet in Clojure
;;; Player
(defn next [p]
(if (= p :P1) :P2 :P1))
;;; Game
(defn winner [game]
(if (= (:pile game) 0) (next (:player game)) nil))
@wtaysom
wtaysom / nim.hs
Created September 4, 2012 02:52
Nim Minimal Viable Snippet in Haskell
import Data.Maybe (isJust, isNothing, fromJust, fromMaybe)
import Data.List (find)
import Control.Applicative ((<|>))
--- Player ---
data Player = P1 | P2 deriving (Show, Eq)
next :: Player -> Player
next P1 = P2
@wtaysom
wtaysom / methodfinder_what.rb
Created December 19, 2011 10:48
_why's Ruby MethodFinder addition tweaked and revised.
require 'methodfinder'
# _why's MethodFinder addition tweaked and revised.
# <http://redhanded.hobix.com/inspect/stickItInYourIrbrcMethodfinder.html>
class MethodFinder
def self.with_redirected_streams
redirect_streams
yield
ensure
@wtaysom
wtaysom / gist:1427232
Created December 3, 2011 14:16
SVN ignore is a pain. This script soothes it.
#!/usr/bin/env ruby -wKU
## A response to <http://jacobian.org/writing/svn-usability/>.
USAGE = <<USAGE
usage: svnignore [--stop] [FILE...]
Tells SVN to ignore each FILE.
Recurses into directories as needed.
--stop stops SVN from ignoring each FILE.
USAGE
@wtaysom
wtaysom / README.md
Last active August 29, 2015 14:04
Interactive Bayes Rule
<style type="text/css"> .posterior { color: hsl(120, 95%, 38%); } .prior { color: hsl(0, 95%, 38%); } .sensitivity {