python string pythonorg code example
Example 1: define a string in python
string1 = "something"
string2 = 'something else'
string3 = """
something
super
long
"""
Example 2: string template python
from string import Template
poem = Template('$x are red and $y are blue')
print(poem.substitute(x='roses', y='violets'))
#>>>roses are red and violets are blue