Dear VBman,
I had problem a with Dev-C++. It would not hold the console output screen for me to view. So I inserted the following line.
Insert the line
system ("PAUSE");
just before return 0;
and this will hold the output screen.
Dev-C++ version 5 is somewhat better and now available...