Colab

greeneggs = "Do you like\n" + "Green eggs and ham\n" + "I do not like them\n" + "Sam-I-am\n"
print(greeneggs)

Do you like
Green eggs and ham
I do not like them
Sam-I-am

# literal strings do not need + to concatenate
greeneggs = "Do you like\n"  "Green eggs and ham\n"  "I do not like them\n"  "Sam-I-am\n"
print(greeneggs)

Do you like
Green eggs and ham
I do not like them
Sam-I-am

# use \ at end of lines to continue at the next line
greeneggs = \
    "Do you like\n"  \
    "Green eggs and ham\n"  \
    "I do not like them\n"  \
    "Sam-I-am\n"
print(greeneggs)

Do you like
Green eggs and ham
I do not like them
Sam-I-am

greeneggs = """
Do you like
Green eggs and ham
I do not like them
Sam-I-am
I do not like
Green eggs and ham
Would you like them
Here or there?
I would not like them
Here or there
I would not like them
Anywhere
I do not like
Green eggs and ham
I do not like them
Sam-I-am
"""
print(greeneggs)


Do you like
Green eggs and ham
I do not like them
Sam-I-am
I do not like
Green eggs and ham
Would you like them
Here or there?
I would not like them
Here or there
I would not like them
Anywhere
I do not like
Green eggs and ham
I do not like them
Sam-I-am

greeneggs = """Do you like
Green eggs and ham
I do not like them
Sam-I-am
I do not like
Green eggs and ham
Would you like them
Here or there?
I would not like them
Here or there
I would not like them
Anywhere
I do not like
Green eggs and ham
I do not like them
Sam-I-am
"""
print(greeneggs)

Do you like
Green eggs and ham
I do not like them
Sam-I-am
I do not like
Green eggs and ham
Would you like them
Here or there?
I would not like them
Here or there
I would not like them
Anywhere
I do not like
Green eggs and ham
I do not like them
Sam-I-am

print(r"""\n""")

\n
quoting_works_freely = """
I like "sarcasm"
and qouting smart people like this
'everything should be as simple as possible, but no simpler'
-- albert einstein
"""
print(quoting_works_freely)


I like "sarcasm"
and qouting smart people like this
'everything should be as simple as possible, but no simpler'
-- albert einstein

repr("\n")

"'\\n'"
str("\n")

'\n'
x= [3,2,1]
print(sorted(x))
print(x)
result = x.sort()
print(x)
print(result)

[1, 2, 3]
[3, 2, 1]
[1, 2, 3]
None