Create PutApples.cpp

The solution to http://dsalgo.openjudge.cn/dsmoochw2/4/