I need help
So In The program below I tried to make a way to make a coding editor like repl. But on line 46 in file It.py All the if statments dont work. Can Someone tell me whats wrong? Thank you!
This is because you are saying if "newline" only, not that if write == "newline"
if write == "NEWLINE" or write == "Newline" or write == "newline": f.write("\n")
Here's your problem, you can't put or and then not put the operator, so line 46 needs to be
if write == 'NEWLINE or Newline" or write == "newline":
However, this is unnecessary since you can shorten that whole line to this
if write.lower() == 'newline': which lowers all the text.