| ■37568 / ) |
intの2次元配列をCSVとして出力する関数です |
□投稿者/ ryo (3回)-(2009/06/25(Thu) 12:54:10)
|
分類:[.NET 全般]
intの2次元配列をCSVとして出力する関数です。 最初からどういう風に流れるか解かりません。教えてください。 宜しくお願いします。
public void putCSV( List<List<Integer>> tableData ){ int row=0; for(List<Integer>rowData:tableData){ int col=0; for(Integer cellData:rowData){ if( (rowData.size() > col) && (col!=0) ){ System.out.print(","); } System.out.print( cellData ); col++; } System.out.println(); row++; } }
|
|