Gregory Petrosyan wrote: > My question is: why write(''.join(...)) works slowly than > writelines(...)? Here's the code: the first copies all the substring to a single string large enough to hold all the data, before handing it over to the file object, while the second just writes the substrings to the file object. </F>