Monads for the Curious Programmer: Part 2
In my previous post I talked about categories, functors, endofunctors, and a little about monads. Why didn’t I just start with a Haskell definition of a monad and skip the math? Because I believe that...
View ArticleMonads for the Curious Programmer: Part 3
In the previous installment I introduced monads using two examples: the Maybe monad and the List monad. Admittedly, those weren’t the most exciting uses of monads, although they served the purpose of...
View ArticleBoostcon, Day 2
I’m totally exhausted, so I won’t write much. I spoke to the audience practically non-stop for three hours, and then I was rewriting Proto with Joel Falcou and Hartmut Kaiser over beers till late at...
View ArticleMonads in C++
“You must be kidding!” would be the expected reaction to “Monads in C++.” Hence my surprise when I was invited to Boostcon 11 to give a three-hour presentation on said topic, a presentation which was...
View ArticleBoostcon Haskell C++ Videos
The videos and the slides of my Boostcon talks, “Haskell — The Pseudocode Language for C++ Metaprogramming” and now available online, courtesy my employer, Corensic. They cover some of the material...
View ArticleTen Things You Should Know About Haskell Syntax
I have posted a new blog about Haskell that I think may be read and understood by any curious programmers. It’s about Haskell syntax, which seems very weird at first but actually makes a lot of sense.
View ArticleNew Approach to Web Programming
A web programmer must be fluent in at least four languages: HTML, CSS, JavaScript, and a fourth language for writing server code. There’s nothing wrong with having specialized domain-specific languages...
View ArticleDesigning the Haskell IDE
I published a new blog post at the FP Complete site, with a peek at our efforts to create the Haskell IDE. I concentrated mostly on the interaction between the programmer and the IDE. I’ve been always...
View ArticleSchool of Haskell
At last I can start blabbing about it. The School of Haskell went beta. We’ve been working on it for the last half a year with a team of top-notch Haskell programmers. Our main effort is to create an...
View ArticleThe Tao of Monad
Anybody who tries to popularize Haskell has to deal with the monad problem. You can’t write the simplest Haskell program without a monad (the IO monad in particular) and yet there is no easy way to...
View ArticleBeautiful Concurrency
I’ve been dealing with concurrency for many years in the context of C++ and D (see my presentation about Software Transactional Memory in D). I worked for a startup, Corensic, that made an ingenious...
View ArticleUnderstanding Yoneda
You don’t need to know anything about category theory to use Haskell as a programming language. But if you want to understand the theory behind Haskell or contribute to its development, some...
View ArticleUnderstanding F-Algebras
What is algebra? Naively speaking algebra gives us the ability to perform calculations with numbers and symbols. Abstract algebra treats symbols as elements of a vector space: they can be multiplied by...
View ArticleBasics of Haskell
My Haskell tutorial series keeps growing. I am publishing it through my School of Haskell account because it includes code that can be edited and run in place. There are many interactive exercises...
View ArticleLenses, Stores, and Yoneda
Edward Kmett’s lens library made lenses talk of the town. This is, however, not a lens tutorial (let’s wait for the upcoming Simon Peyton Jones’s intro to lenses (edit: here it is)). I’m going to...
View ArticleYou Can’t Make an Algebra without Breaking a Few Eggs
In my previous post I worked on stretching the intuition of what a container is. I proposed that, in Haskell, any functor may be interpreted as some kind of container, including the hard cases like the...
View ArticleNatural Transformations and Ends
In category theory we never look inside objects. All information about objects is encoded in the arrows (morphisms) between them. In set theory, on the other hand, we express properties of sets through...
View ArticleFunctors are Containers
For an outsider, Haskell is full of intimidating terms like functor, monad, applicative, monoid… These mathematical abstractions are hard to explain to a newcomer. The internet is full of tutorials...
View ArticleExponentials, Currying, and Universal Constructions
Haskell is a language deeply rooted in category theory. But as you don’t need to study the root system of Vitis vinifera in order to enjoy a glass of wine, you don’t need to know much about category...
View ArticleParametricity: Money for Nothing and Theorems for Free
I’m not fond of arguments based on lack of imagination. “There’s no way this code may fail!” might be a sign of great confidence or the result of ignorance. The inability to come up with a...
View Article