It's a really great introduction to a non-trivial bit of Haskell.
It's a really great introduction to a non-trivial bit of Haskell.
I (and thousands of others at HN) really enjoyed Jeremy Ruten's tutorial of building antirez's 1000-line text editor, Kilo, from scratch (antirez is the author of Redis which is renowned for its code quality and approachability) - http://viewsourcecode.org/snaptoken/kilo/ . Additionally, the author of that walkthrough has published the project used to create that tutorial here - https://github.com/yjerem/leg
I realize this might be less trivial than creating a Youtube video, but if you have the bandwidth I'm certain creating a similar walkthrough for Legion would not go unappreciated here :)
Kilo is quite a bit bigger.
With respect and praise offered to the author, Legion is a simple project. I think an approach of building it interactively and showing how a developer actually makes the types line up and uses the tooling probably answers more questions about what it's like to use Haskell than you may give it credit for.
I can definitely also see your argument that a smaller and more straightforward project may be easier to explain. As someone at least superficially acquainted with how blockchain technology works, my fear was that a lack of understanding of the thing being built might be a stumbling point for readers/listeners of a line-by-line code walkthrough.
However, you seem confident that a line-by-line will be sufficient to explain both the Haskell and bitcoin sides of things concisely, so I'll defer to your judgment, and look forward to it!
Anytime anyone asks me how they work I say, "They don't, actually. They're really a data integrity system that's being misused, and the current economically motivated implementations (currency) are motivated by the assumption that a majority of computing power in the system is guaranteed to work with the system and not try to take it over."
I will probably avoid that conversation.
Please let me know if you end up doing that!
And your code is just very clean and approachable and doesn't try to do popular gymnastics. I'll ping you via GitHub.
It's an old pet peeve of mine. I cringe inside every time someone starts waxing about "writing your thoughts first, and your code only incidentally" or "it's a completely different paradigm of programming" and other such pieces of useless, discouraging new age fluff.
The idea is that you write a "Book" and the program is extracted, from the book.
Literate Programming Wikipedia: https://en.wikipedia.org/wiki/Literate_programming
A nice talk about it: https://youtu.be/Av0PQDVTP4A
(Definitely peak HN if it runs in the browser).
Edit: https://webghc.github.io