This Drum Machine project was a satisfying one to complete.

At times I doubted whether or not I would get everything to work the way I wanted. But in the end it all worked out and the project came together quite nicely.

Here's my demo and the source code.

Whether you choose to just read the code or to build the project you will learn the following:

How to play audio. How to write a custom decoder for key up and down events. How to use Process.sleep to do the equivalent of JavaScript's setTimeout . How make Elm output special HTML characters like non-breaking space.

I challenge you to build something, anything, in Elm. It's the best way to learn the language.