Answer the question
In order to leave comments, you need to log in
How to write each result in txt on a new line?
You need to take the result from here:
result = f'{phone} | {seller} | {title} | {description} | {price} | {location} | {district} | {date} | {photo0} | {photo1} | {photo2}'
Answer the question
In order to leave comments, you need to log in
Add a line break to the end of the line. Example:
from datetime import datetime
with open('data.txt','a') as file:
file.write(str(datetime.now())+'\n')
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question