Re: [NooB] a Variable in multiple quotes...
Leif K-Brooks [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... administrata wrote: Is it possible? I tried... I = John print \ I used to love pizza Error occurs!!! No error occurs; it prints I used to love pizza, as would be expected. Oh: from the subject line, I'm guessing that you want it to say John used to love pizza instead? In that case, try doing this: I = John print %s used to love pizza % I How can I do it with several variables? About 10 or more... HELP plz :) -- http://mail.python.org/mailman/listinfo/python-list
Re: [NooB] a Variable in multiple quotes...
administrata wrote: Oh: from the subject line, I'm guessing that you want it to say John used to love pizza instead? In that case, try doing this: I = John print %s used to love pizza % I How can I do it with several variables? About 10 or more... two: print I, used to love, J or print %s used to love %s % (I, J) three: print I, used to, J, K print %s used to %s %s % (I, J, K) five: print I, J, to, K, L, M print %s %s to %s %s %s % (I, J, K, L, M) (you get the idea) for more on this, and some variations, read the fancier output formatting chapter in the tutorial again: http://docs.python.org/tut/node9.html (you've read the tutorial before, right?) /F -- http://mail.python.org/mailman/listinfo/python-list
[NooB] a Variable in multiple quotes...
Is it possible? I tried... I = John print \ I used to love pizza Error occurs!!! But, I don't know how to fix... HELP thx 4 reading. -- http://mail.python.org/mailman/listinfo/python-list
Re: [NooB] a Variable in multiple quotes...
It's OK for me @-salutations -- Michel Claveau -- http://mail.python.org/mailman/listinfo/python-list
Re: [NooB] a Variable in multiple quotes...
administrata wrote: Is it possible? I tried... I = John print \ I used to love pizza Error occurs!!! No error occurs; it prints I used to love pizza, as would be expected. Oh: from the subject line, I'm guessing that you want it to say John used to love pizza instead? In that case, try doing this: I = John print %s used to love pizza % I -- http://mail.python.org/mailman/listinfo/python-list
Re: [NooB] a Variable in multiple quotes...
Michael Hoffman wrote: This is a fairly friendly group and they will answer even newbie questions amicably. Albeit with the occasional pointed comment about not at least skimming the tutorial when it covers the question asked ;) Cheers, Nick. -- Nick Coghlan | [EMAIL PROTECTED] | Brisbane, Australia --- http://boredomandlaziness.skystorm.net -- http://mail.python.org/mailman/listinfo/python-list