Skip to content
InfoQ·

💻J Incunabulum: A Legendary 1K Line C Interpreter

This 1K line C code is so dense, only its author can understand it

TL;DR

Arthur Whitney's J Incunabulum is a 1,000-line C interpreter for the J language. It's so dense, only its author can understand it. APL, the language it's based on, was popular in financial institutions in the 1970s.

Arthur Whitney's J Incunabulum is a 1,000-line C interpreter for the J programming language. It includes an object model, memory management, a standard library, a parser, a lexer, and a REPL. The code is so dense that only its author can comprehend it, embodying the concept of 'write-only software'. APL, the language J is based on, was proposed by Ken Iverson in 1962 and was popular in financial institutions in the 1970s. This dense, complex code challenges the notion of maintainable software.

J Incunabulum: A Legendary 1K Line C Interpreter — InfoQ

Key Points

1

Arthur Whitney's J Incunabulum is a 1,000-line C interpreter for the J language, written in 1999.

2

J Incunabulum includes an object model, memory management, a standard library, a parser, a lexer, and a REPL.

3

APL, the language J is based on, was proposed by Ken Iverson in 1962 and was popular in financial institutions in the 1970s.

4

Regular expressions are often considered write-only code due to their complexity and lack of readability.

5

The J language uses a mathematical notation to manipulate arrays, making it effective for rapid development.

Why It Matters

If you're working on dense, complex codebases, J Incunabulum is a cautionary tale. The code is so intricate that only its author can understand it, making maintenance a nightmare. This challenges the idea of writing maintainable software and highlights the trade-offs between complexity and readability.

J IncunabulumArthur WhitneyCJ languageAPLwrite-only software

Comments

Subscribe to join the conversation...

Be the first to comment

Enjoyed this article?

Get it daily. 7am. Free. Reads in 5 minutes.

Join 3,483 builders reading daily.

Also get