Skip to content

Instantly share code, notes, and snippets.

View witt3rd's full-sized avatar
⌨️
coding

Donald Thompson witt3rd

⌨️
coding
View GitHub Profile
@witt3rd
witt3rd / python.md
Last active September 7, 2021 13:29
Python
@witt3rd
witt3rd / kelly.md
Last active August 31, 2021 17:05
For Kelly

Never going to give you up

@witt3rd
witt3rd / unity.md
Last active May 5, 2021 19:36
Unity

Unity

Setup

  • Install the Unity Hub
  • Use the hub to install the latest LTS (long-term support) editor (e.g., 2020.3.6f1 LTS)
  • No additional modules are needed during the editor install, so accept the defaults

Projects

@witt3rd
witt3rd / scala.md
Last active April 18, 2021 14:08
Scala installation, setup, and usage notes

Scala

Install

Installers

These CLI utilities are used to fetch things we need.

@witt3rd
witt3rd / Pluto.jl.md
Last active October 13, 2020 20:36
Working in Pluto.jl
@witt3rd
witt3rd / pluto-test.jl
Created October 13, 2020 11:49
Test of online interactive notebook
### A Pluto.jl notebook ###
# v0.12.3
using Markdown
using InteractiveUtils
# This Pluto notebook uses @bind for interactivity. When running this notebook outside of Pluto, the following 'mock version' of @bind gives bound variables a default value (instead of an error).
macro bind(def, element)
quote
local el = $(esc(element))
data Foo a = Bar a
| Baz (Foo a) (Foo a)
fooEq : DecEq a => a -> a -> Foo a -> Foo a -> Maybe (Foo a)
fooEq x y f g = case decEq x y of
Yes _ => Just (Baz f g)
No _ => Nothing
comb : DecEq a => Foo a -> Foo a -> Maybe (Foo a)
comb f@(Bar x ) g@(Bar y ) = fooEq x y f g -- < ok
@witt3rd
witt3rd / zed.md
Last active October 8, 2020 13:40
Z notation

Z Notation (zed)

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{zed-csp}
\usepackage{amsthm}

\theoremstyle{definition}
data Foo : (x : List a) -> (y : List b) -> Type where
MkFoo : (bar: a -> b) -> Foo x y
bar : Foo {a} {b} x y -> a -> b
bar (MkFoo _) x' = ?rhs
{-
b : Type
a : Type
y : List b
record Foo where
constructor MkFoo
from : Type
to : Type
bar : (a : Foo) -> (x : from a) -> (to a)
-- impl not important
baz : (a : Foo) -> (b : Foo) -> ((to b) = (from a)) => (x: from b) -> (to a)