cpplearning: add some example code