Computer Science
How many string types does Python support? How are they different from one another?
Python Data Handling
56 Likes
Answer
Python supports two types of strings — Single-line strings and Multi-line strings. Single line strings are enclosed in single or double quotes and terminate in one line. Multi-line strings store multiple lines of text and are enclosed in triple quotes.
Answered By
33 Likes
Related Questions
What will following code print?
str1 = '''Hell o''' str2 = '''Hell\ o''' print(len(str1) > len(str2))
The complex numbers have two parts : real and imaginary. In which data type are real and imaginary parts represented ?
How are these numbers different from one another (with respect to Python)? 33, 33.0, 33j, 33 + j
What are Immutable and Mutable types in Python? List immutable and mutable types of Python.