using txt file as input for python
I have a python program that requires the user to paste text to it to
process it to da various tasks. Like this:
line=(input("Paste text here: ")).lower()
The pasted text comes from a .txt file. To avoid any issues with the code
(since the text contains multiple quotation marks), the user has to do the
following: type 3 quotation marks, paste the text and type 3 quotation
marls again.
Can all of the above be avoided by having python read the .txt? and if so,
how?
Please let me know if the question makes sense.
No comments:
Post a Comment