Hello, I'm a starter in Python and I need help. I'm trying to ask the user to input as much text as he/she likes until he/she types EOF (end of file) on a separate line. Once he/she does, the program should end. I started on my code and below is what I have so far. I'm using the 'for' loop in my code, is that correct?
#Set textInput to 0? textInput = 0 #Use the 'for' loop to keep looping. for i in textInput: #Prompt for user text input. Is this in the right spot? textInput = input() #If the user types EOF on a new line, then end the program. if textInput == "\n" and textInput == "EOF": break #Keep going until EOF is typed. Is this right? else: continue