SyntaxFix
Write A Post
Hire A Developer
Questions
from this link:
you can use rstrip() method. Example
mystring = "hello\n" print(mystring.rstrip('\n'))