Skip to content

Instantly share code, notes, and snippets.

View novusnota's full-sized avatar
:accessibility:
be curious, do better, and remember — it's more fun to be competent

Novus Nota novusnota

:accessibility:
be curious, do better, and remember — it's more fun to be competent
View GitHub Profile
@novusnota
novusnota / ANSI.md
Created December 19, 2024 00:19 — forked from fnky/ANSI.md
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@novusnota
novusnota / imaginary-book-club.md
Created January 11, 2025 16:49 — forked from jcreedcmu/imaginary-book-club.md
Imaginary Book Club

Welcome to imaginary book club! I hope everyone finished the reading this week. No? Fine, we'll just wing it. At least there's snacks.

There is a deck of cards. Each has a question on it. Play starts with a random player and proceeds in a circle, with each player drawing a card and answering the question. The first two are always:

  • What is the book's title?
  • What is the book's genre?
@novusnota
novusnota / CoC-60.ml
Created May 14, 2025 17:17 — forked from hirrolot/CoC-60.ml
Calculus of Constructions in 60 lines of OCaml
let discard _a b = b
let rec pp lvl = function
| `Lam f -> "(λ" ^ pp (lvl + 1) (f (`Go lvl)) ^ ")"
| `Pi (a, f) -> "(Π" ^ pp lvl a ^ "." ^ pp (lvl + 1) (f (`Go lvl)) ^ ")"
| `Appl (m, n) -> "(" ^ pp lvl m ^ " " ^ pp lvl n ^ ")"
| `Ann (m, a) -> "(" ^ pp lvl m ^ " : " ^ pp lvl a ^ ")"
| `Go x -> string_of_int x
| `Star -> "*"
| `Box -> "☐"