Skip to content

Instantly share code, notes, and snippets.

View ryx's full-sized avatar
🕶️
Never stop learning

Rico Pfaus ryx

🕶️
Never stop learning
  • Berlin, Germany
View GitHub Profile
@onlurking
onlurking / programming-as-theory-building.md
Last active May 6, 2025 06:16
Programming as Theory Building - Peter Naur

Programming as Theory Building

Peter Naur

Peter Naur's classic 1985 essay "Programming as Theory Building" argues that a program is not its source code. A program is a shared mental construct (he uses the word theory) that lives in the minds of the people who work on it. If you lose the people, you lose the program. The code is merely a written representation of the program, and it's lossy, so you can't reconstruct

@0x263b
0x263b / colors.md
Last active January 26, 2025 20:10
Random color from string in javascript

Random color from string in javascript

Consider a list of strings you need to permanently assign a random color.

First you should turn the string into a hash.

var string = "string"
var hash = 0