(Oct-26-2017, 09:30 PM)Larz60+ Wrote: shouldn't the mode be plain 'w', rather than 'wt'? (line 48)
Well thats not the problem w and wt is alost the same thing here. My problem is if i generete 10 lines of data and save it only the 10th or last line is saved to the file and the file does not get the *.txt
The t indicates text mode, meaning that \n characters will be translated to the host OS line endings when writing to a file, and back again when reading. The flag is basically just noise, since text mode is the default.