2014-01-17 05:32:22 +00:00
|
|
|
var file, str;
|
|
|
|
|
file = file_text_open_read("input.txt");
|
|
|
|
|
str = "";
|
2015-02-20 09:02:09 -05:00
|
|
|
while (!file_text_eof(file))
|
2014-01-17 05:32:22 +00:00
|
|
|
{
|
|
|
|
|
str += file_text_read_string(file);
|
2015-02-20 09:02:09 -05:00
|
|
|
if (!file_text_eof(file))
|
2014-01-17 05:32:22 +00:00
|
|
|
{
|
2015-02-20 09:02:09 -05:00
|
|
|
str += "
|
|
|
|
|
"; //It is important to note that a linebreak is actually inserted here rather than a character code of some kind
|
2014-01-17 05:32:22 +00:00
|
|
|
file_text_readln(file);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
file_text_close(file);
|
|
|
|
|
|
|
|
|
|
file = file_text_open_write("output.txt");
|
|
|
|
|
file_text_write_string(file,str);
|
|
|
|
|
file_text_close(file);
|