In Python, when you need to get a sequence of characters from a string (i.e., a substring), you get a slice of the string using the following syntax:
In Python, when you need to get a sequence of characters from a string (i.e., a substring), you get a slice of the string using the following syntax: