added .cpp and mainfile