[ create a new paste ] login | about

Link: http://codepad.org/8LpgXzLt    [ raw code | output | fork ]

C++, pasted on May 19:
1
2
3
4
5
6
7
8
9
10
11
		ifstream fs("id.txt");
		string s;
		getline(fs, s);
		fs.close();
		id = atoi(s.c_str())+1;
		cout << "id=" << id << endl;
		s= to_string(id);
		cout << "zzzzs=" << s << endl;
		ofstream out("tele2.txt", ios::trunc);
		out << s;
		out.close();


Output:
1
2
Line 3: error: expected constructor, destructor, or type conversion before '(' token
compilation terminated due to -Wfatal-errors.


Create a new paste based on this one


Comments: