Page 2 of 2

Re: Long Line Split

Posted: Fri Oct 09, 2009 8:02 am
by bembulak
Just out of curiosity can anyone name a language which does not use an end of line character and allows multiple lines of text across several lines?
Python!

Code: Select all

normalstring = "I'm a string"    #string in normal quotes
anothernormalstring = 'Me too!'    #string in single quotes, less "noise"
aVeryLongString = """This String starts here and
continues her in the next line.

Ah, the string does not end here! I'ts going on and on. Since it's triple-quoted,
I can use normal "quotes" here and 'here'!
Cool!"""

# Statement over several lines:
myList = (for thing in thinglist \
if thing == "list comprehension")

# Joined statements:
print mylist : print "done"

Re: Long Line Split

Posted: Fri Oct 09, 2009 3:01 pm
by Little John
maker wrote:A small point, perhaps, but a point nevertheless.
I agree to this point. And let's bear in mind, that many a little makes a mickle. :-)

Regards, Little John