27Aug  Admin

Strings are amongst the most popular types in Python. We can create them simply by enclosing characters in quotes. Python treats single quotes the same as double quotes. Creating strings is as simple as assigning a value to a variable. For example −

a = 'Hello World!'

You can display a string  with the print() function:

x = “Welcome”    #Assigning a string to a variable
print(x)

Output– Welcome