Danny <> wrote:
>The programs output will be:
>text
>text
>(etc)
>
>How could I make this print: texttexttexttexttext?
>Ive researched and looked through google and so far I can't find
>anything that will help (or revelent for that matter).
I'm kind of surprised this isn't a FAQ (if it's in the FAQs, I
can't find it).
http://docs.python.org/tut/node5.htm...00000000000000
tells you how to use
print "text", # Note the comma. Oh, and the correct comment character.
to get
text text text text text
http://docs.python.org/tut/node9.htm...00000000000000
hints that what you want may be
sys.stdout.write("text")
to get
texttexttexttexttext
Beware that in either case you'll need an additional print at the
end of the loop to get the final newline back.
--
\S --
--
http://www.chaos.org.uk/~sion/
___ | "Frankly I have no feelings towards penguins one way or the other"
\X/ | -- Arthur C. Clarke
her nu becomež se bera eadward ofdun hlęddre heafdes bęce bump bump bump