Python Substring, In Python, substrings can be obtained by using the slicing feature on a string variable.