场景:
1. 就是合并文本文件,并且从第2个文件起不要合并第一行.
2. 多加了一个功能,就是支持2个以上的文件合并.
3. 问题: http://ask.youkuaiyun.com/questions/192151
只能说很简单: 基础不过关吧,这位同学,也有可能不是开发的,放这里也是为了培训基础差的.
test.cpp
#include <fstream>
#include <string>
#include <iostream>
using namespace std;
//最后一个参数是输出文件.
//支持多余2个的文件合并
//用法,命令行: test.exe 1.txt 2.txt output.txt
int main(int argc, char const *argv[])
{
cout << "usage1: test.exe 1.txt 2.txt output.txt" << endl;
cout << "usage2: test.exe 1.txt 2