added mainxcode.cpp