(Wild guess) You wrote a console application, something like
#include <iostream>
int main()
{
std::cout << "hi there!" << std::endl;
}
In such a case the behaviour you described is the correct one: the application starts, produces the output and (quickly) terminates. If you need a chance to see the output you have to stop its execution (at least for a while). You can, for instance, pause it with a synchrounous input request:
#include <iostream>
int main()
{
std::cout << "hi there!" << std::endl;
std::cin.get(); }
Alternatively, you might launch your console application from the command prompt.