hacks

(tidier examples of) random scripts from throughout the years
Log | Files | Refs | README

commit 91cf00dc343e2ed3e870171f8199e8a1ce75689a
parent d952741be1685319daa8077e2f99e0b15349ad42
Author: quantumish <freifeld.david@gmail.com>
Date:   Wed, 29 Jul 2026 01:55:30 -0700

Add rough creation dates to each file

Diffstat:
Mdiffgame.py | 1+
Mgap.c | 1+
Mprob.lisp | 1+
Mregex.lisp | 1+
Mropes.sml | 2+-
Mstack.lisp | 1+
Mturing.sml | 2+-
Mu235.rs | 1+
8 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/diffgame.py b/diffgame.py @@ -1,5 +1,6 @@ # Editor's note: Simulations for a problem in my high school differential equations class. # I remember very little about how this works, but it produces some flashy GIFs. +# Written around September 2022. # # The Game # diff --git a/gap.c b/gap.c @@ -1,6 +1,7 @@ /** * Editor's note: A simple program that demonstrates how a gap buffer works. * I wrote this in order to have a visual demo for my 15-122 TA interview! + * Written around the fall of 2023. * * Fun fact (and another demo I did during my interview): you can see how a * gap buffer is used in Emacs by calling the functions (gap-position) and diff --git a/prob.lisp b/prob.lisp @@ -1,5 +1,6 @@ ;; Editor's note: Helper script written for a Nature of Reason (80-150) probability assignment. ;; An underrated quality of s-expressions is that you get to have simple rational literals... +;; Written around the spring of 2024. (load "~/quicklisp/setup.lisp") diff --git a/regex.lisp b/regex.lisp @@ -1,5 +1,6 @@ ;; Editor's note: Experiments with Coalton and the paper "A Play on Regular Expressions" ;; by Sebastian Fischer, Frank Huch, and Thomas Wilke. +;; Written around the summer of 2024. (ql:quickload :coalton) diff --git a/ropes.sml b/ropes.sml @@ -1,6 +1,6 @@ (* Editor's note: transmuting an assignment from one CMU class to another... * Sometimes things are easier when the language isn't fighting you :) - * Comments are lightly edited. *) + * Comments are lightly edited. Written around the spring of 2024. *) datatype rope = Leaf of string | Cat of rope ref * rope ref diff --git a/stack.lisp b/stack.lisp @@ -2,6 +2,7 @@ ;; her asking me why her Emacs Lisp function was hitting a recursion limit. ;; This was only a couple days after I had finished 15-150's CPS lab so the ;; timing was great for me to get nerdsniped into talking about CPS and stacks. +;; Written around 2024 spring. ;; ;; As you just discovered, some recursive functions are not "stack-safe" diff --git a/turing.sml b/turing.sml @@ -1,5 +1,5 @@ (* Editor's note: A random script I wrote for a Nature of Reason (80-150) assignment. - * The below introductory comment is taken from my submission: + * Written around spring 2024. The below introductory comment is taken from my submission: * * I was procrastinating a bit last week and so I wrote up a little Standard ML program to * simulate a Turing Machine! diff --git a/u235.rs b/u235.rs @@ -7,6 +7,7 @@ //! ``` /// Editor's note: a pretty silly joke library based on a pun. +/// Written on December 21, 2022. use std::time::{Instant, Duration}; use bnum::cast::{As, CastFrom};