added learning.cpp
a working c++ program