I need to write for each line by line into the same text file for every few minutes, but my problem is whenever I run the code, the text file came out nothing instead of hav