We are currently working on new rules for what content should and shouldn't be allowed on this website, and are looking for feedback! See Esolang:2026 topicality proposal to view and give feedback on the current draft.
λfuck
Jump to navigation
Jump to search
- This is still a work in progress. It may be changed in the future.
λfuck is an esoteric programming language made by User:IAm DeLynn. It's based on the de Bruijn notation of untyped lambda calculus in brainfuck-like syntax.
Syntax
Whitespace is ignored.
Expressions
| Expression | De Bruijn notation | Description |
|---|---|---|
.
|
0
|
Free variable |
+ ++ +++ ... + × (n + 1)
|
1 2 3 ... n + 1
|
Bound variable with index n + 1 |
[M]
|
λ M
|
Declare new functional expression (Abstraction) |
M N
|
M N
|
Apply argument N to a function M (Application) |
(M)
|
(M)
|
Higher priority for an expression |
Grammar
<expr> ::= <atom> { <atom> }
<atom> ::= '.' | '+' { '+' } | '(' expr ')' | '[' expr ']'
Examples
Identity
[+]
K-combinator
[[++]]
S-combinator
[[[(+++)(+)((++)(+))]]]
Iota-combinator
[+[[[(+++)(+)((++)(+))]]][[++]]]
Implementation
- Parser (Only builds an AST, doesn't calcuate any expressions)