That is C code, not C++. Are you sure you are in a c++ class?
for a fstream tutorial
click here.
cout is quite easy to learn. First you have to include <iostream> header file -- it does not have a .h extension. Then declare the std namespace.
#include <iostream>
using std::cout;
int main()
{
cout << "Hello World\n";
}
Sponsor
Team Colleague
Featured Poster
Reputation Points: 5608
Solved Threads: 2282
Retired and Enjoying Life
Offline 21,950 posts
since Aug 2005