adding main3.cpp