Monthly Archives: September 2021

Swarm: preview and call for collaboration

For about a month now I have been working on building a game1, tentatively titled Swarm. It’s nowhere near finished, but it has at least reached a point where I’m not embarrassed to show it off. I would love to … Continue reading

Posted in haskell, projects | Tagged , , , , | 6 Comments

Competitive programming in Haskell: Codeforces Educational Round 114

Yesterday morning I competed in Educational Round 114 on codeforces.com, using only Haskell. It is somewhat annoying since it does not support as many Haskell libraries as Open Kattis (e.g. no unordered-containers, split, or vector); but on the other hand, … Continue reading

Posted in competitive programming, haskell | Tagged , | 2 Comments

Automatically updated, cached views with lens

Recently I discovered a nice way to deal with records where certain fields of the record cache some expensive function of other fields, using the lens library. I very highly doubt I am the first person to ever think of … Continue reading

Posted in haskell | Tagged , , , | 10 Comments

Competitive programming in Haskell: Kadane’s algorithm

I will be giving a talk on competitive programming in Haskell tomorrow, September 10, at Haskell Love. You should attend! It’s free! In my last competitive programming post, I challenged you to solve Purple Rain. We are presented with a … Continue reading

Posted in competitive programming, haskell | Tagged , , , , | 1 Comment

Implementing Hindley-Milner with the unification-fd library

For a current project, I needed to implement type inference for a Hindley-Milner-based type system. (More about that project in an upcoming post!) If you don’t know, Hindley-Milner is what you get when you add polymorphism to the simply typed … Continue reading

Posted in haskell, teaching | Tagged , , , | 3 Comments