'Hello'

"""
Explanation: Lesson 19:
Advanced String Syntax
A string is a single quote:
End of explanation
"""


print("That is Alice's cat.")
print('Say hi to Bob\'s mother.')

"""
Explanation: Strings can be written in different ways using escape characters and other symbols.
End of explanation
"""


print('\'') # Single quote
print('\"') # Double quote
print('\t') # Tab
print('\n') # New line
print('\\') # Back slash

"""
Explanation: Many escape characters are available:
End of explanation
"""


print(r'That is Carol\'s cat.')

"""
Explanation: Use r'' to print raw strings, where all characters are treated as strings.
End of explanation
"""


print("""Dear Alice,
Eve's cat has been arrested for catnapping, cat burglarly, and extortion. 
Sincerly, Bob.""")

"""
Explanation: Multi line strings (with '''' or """ are often easier.)
End of explanation
"""


import requests # get the Requests library

link = "https://automatetheboringstuff.com/files/rj.txt" # store the link where the file is at
rj = requests.get(link) # use Requests to get the link

print(rj.text) # Print out the text from Requests, and check that its stored

"""
Explanation: Large strings are treated in this way.
End of explanation
"""


print(len(rj.text))

"""
Explanation: Functions can now be run on it:
End of explanation
"""


hello = 'Hello World!'

print(hello[0])
print(hello[1:5])
print(hello[-1])
print('Hello' in hello)
print('x' in hello)
print('HELLO' in hello)

"""
Explanation: Strings can be treated like lists where each character is an elemant in that list.
End of explanation
"""


