Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string>
- #include <fstream>
- using namespace std;
- int main() {
- ifstream in ("f1.txt");
- ofstream out("f2.txt");
- while (in) {
- string line;
- getline(in, line);
- if (line.length() % 2 == 0 && line != "")
- out << line << endl;
- }
- in.close();
- out.close();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement