this post was submitted on 14 Nov 2023
23 points (92.6% liked)
Advent Of Code
764 readers
1 users here now
An unofficial home for the advent of code community on programming.dev!
Advent of Code is an annual Advent calendar of small programming puzzles for a variety of skill sets and skill levels that can be solved in any programming language you like.
AoC 2023
Solution Threads
M | T | W | T | F | S | S |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 |
Rules/Guidelines
- Follow the programming.dev instance rules
- Keep all content related to advent of code in some way
- If what youre posting relates to a day, put in brackets the year and then day number in front of the post title (e.g. [2023 Day 10])
- When an event is running, keep solutions in the solution megathread to avoid the community getting spammed with posts
Relevant Communities
Relevant Links
Credits
Icon base by Lorc under CC BY 3.0 with modifications to add a gradient
console.log('Hello World')
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I'm going to try Lean4. It's interesting for us at work, for gamedev, and I'm personally interested in it too.
It's not only a programming language, but also a theorem prover, and the boundaries between those two aspects are rather blurry. For instance,
if
does not take a Boolean as argument, but aDecideable
logical proposition.if
also does not only choose which branch to evaluate, but also offers a proof that the proposition is True or False in the respective branches, that one can later use to argue with the compiler if a certain function call is allowed or not (for instance, one can make a type that only contains natural numbers that are prime - and making an instance of that type requires a proof that the passed in number is indeed prime - and such a proof can be materialized usingif
).I'm still learning the language though, and am not certain if I can finish reading the book Functional Progrmaming in Lean till AoC starts... If I can't manage, I'm just going to start AoC in Lean anyhow, and see how far I get.
Dang, haven’t heard of this, looks pretty cool!