java合并兩個(gè)int數(shù)組 java中怎么將2個(gè)csv數(shù)據(jù)拼接成一個(gè)csv,急急急?
java中怎么將2個(gè)csv數(shù)據(jù)拼接成一個(gè)csv,急急急?//這是合并兩個(gè)文件的問題。您可以將兩個(gè)文件的路徑放入一個(gè)數(shù)組中,然后遍歷數(shù)組public static void main(string[]a
java中怎么將2個(gè)csv數(shù)據(jù)拼接成一個(gè)csv,急急急?
//這是合并兩個(gè)文件的問題。您可以將兩個(gè)文件的路徑放入一個(gè)數(shù)組中,然后遍歷數(shù)組public static void main(string[]args)拋出IOException{string Sourcefile=“full path to read file”string descfile=“full path to write file”BufferedReader input=new BufferedReader(new FileReader(new file)file(Sourcefile)),1024*1024)//true表示追加內(nèi)容而不是重寫bufferedwriter output=new bufferedwriter(new filewriter(new file(descfile),true))string line=null while((line)=input.readLine文件())!=空){輸出.寫入(行)輸出.flush() } 輸入。關(guān)閉() 輸出.關(guān)閉() }