how do i keep python from printing a newline when it exits the program?
__peter__ at web.de
Mon Oct 11 17:35:19 CEST 2004
> print "No newline, please.",
> # End of script
> When the program runs, python is still printing a newline when the
> program exits. How does one keep python from doing so?
Use sys.stdout.write() instead of print or clear the softspace flag
sys.stdout.softspace = False
after the print statement. Google 'site:mail.python.org exit newline' for
More information about the Python-list