First, if you want to understand ML, watch the Stanford ML course lectures by Andrew Ng. If you haven't heard of him, he is a really successful ML researcher. The lectures are available freely here: http://academicearth.org/courses/machine-learning
Then you can start by implementing Hidden Markov Models. They are simple, yet they will make you implement a famous inference algorithm and also understand how to store random variables, probability tables, etc. If you are an experienced programmer, you will enjoy learning how to implement the data structures for Machine Learning algorithms. It is true that most of the ML algorithms can be implemented in about 100 lines of code. But you need to build a lot of coding infrastructure around it to make it usable.