im trying to make a program that will output a spr.txt file to make it go like:
admin forceclass 1 spr
admin forceclass 2 spr
admin forceclass 3 spr
etc. up to 800 for a game
im geting compile errors of sum sort with Dev-C++
any help??Code:#include <fstream> #include <iostream> using namespace std; char func() { int x for ( x = 1, x < 801, x++ ) { cout<<"admin forceclass "<< x <<" spr\n"; } } int main() { cout<<"filesystem creation of spr.txt for americas army."; ofstream spr1 ( "spr.txt" ); spr1>> func(); spr1.close(); cout<<"shud be made"; }