0

How could we write multi line codes if python gives output after each line?

30th Oct 2016, 12:41 PM
Sarthak SG
Sarthak SG - avatar
3 Answers
+ 2
You can create a ".txt" file. Write the code it. and store it in a ".py" format. Well, and then run the finished code Also, use a text editor to edit the code (.py)
30th Oct 2016, 3:07 PM
Met174
+ 2
PEP8 Style Guide: Explicit using \ even inside text: >>> print( \ ... "by using continuation" \ ... ) by using continuation >>> Implicit using (), {} or []: output = my_function( a, b, c) If you aren't in the immediate interpreter (the only place your question applies) then the other answers (use a file) apply. You can also use streams but that's probably a special need.
30th Oct 2016, 8:30 PM
Kirk Schafer
Kirk Schafer - avatar