示例:
Java is a set of several computer software
and specifications developed by Sun Microsystems,
("PROBLEM HOW DO I SKIP THIS SPACE BELOW?")
later acquired by Oracle Corporation, that provides
a system for developing application software and
deploying it in a cross-platform computing environment.
我想知道如何使用Java忽略输出文件中的空白行。
答案 0 :(得分:4)
这是伪代码时间! \ O /
while (file is not read completely) {
line = read a line from file;
if (line is empty) {
continue; // skip this line!
}
process line;
}