filedd

PHOTO EMBED

Sun Apr 25 2021 22:45:37 GMT+0000 (UTC)

Saved by @ahmedqgqgq #java

#include<iostream>
#include<fstream>
#include<string>
using namespace std;
int main()
{
	ofstream Myfiles("Myfiles.txt", ios::in | ios::out | ios::app);// add new words
	if (Myfiles.fail())
	{
		cout << "cant out open file\n";
		exit(1);
	}
	string str;
	
	
	while (cin >> str) 
	{
		if (str=="1"){break;}
		Myfiles << str<<"\n";
	}
	Myfiles.close();
}
content_copyCOPY