anantkhaitan
Burning Bright
Friends point me where I m wrong.
Code:
Command for compilation :
Error message(s):
Code:
#include<fstream>
#include<iostream>
int main()
{
ofstream f;
f.open("1.txt");
f.put(65);
std::cout<<"Inserted";
f.close();
return 1;
}
Command for compilation :
$ g++ a.cpp -o a
Error message(s):
a.cpp: In function ‘int main()’:
a.cpp:5: error: ‘ofstream’ was not declared in this scope
a.cpp:5: error: expected `;' before ‘f’
a.cpp:6: error: ‘f’ was not declared in this scope