0
如何將文本文件重新格式化爲具有給定線寬的新文件?如何將文本文件重新格式化爲具有給定線寬的新文件
例如:
示例文件input.txt
:
Your program should store a single row of the triangle and calculate each subsequent row by adding a value to the values
immediately above it and to its left. The values on each line must be space-separated.
示例文件output.txt
:
Your program should store a single row
of the triangle and calculate each
subsequent row by adding a value to the
values immediately above it and to its
left. The values on each line must be
space-separated.
樣品控制檯I/O:
Enter the input filename:
input.txt
Enter the output filename:
output.txt
Enter the line width:
40