#include <iostream>
#include <string>
#include <cstring>
#include <fstream>
using namespace std;
int main() 
{
    string temp;
    ifstream inFile;
    ofstream outFile;
    inFile.open("ZRMK Matched - 010513.txt");
    outFile.open("second.txt");
    while(!inFile.eof()) {  
        getline(inFile, temp);
        if (temp != "") {
            getline(inFile, temp);
            outFile << temp;
        }
    }
    cout << "Data Transfer Finished" << endl;
    return 0;
}
我很难让这个工作。当我执行程序时,它会循环一段时间,然后在没有完成的情况下终止——它不会将任何文本行输出到输出文件。任何帮助,将不胜感激。