String Datatype in Python

String are immutable collections in python, consist of ordered set of unicode characters.

Example Code

my_name = 'Jay'
message = 'i am learning python'
print('we can use numbers as string')
print(f'example: {string_num} is of {type(string_num)} type')
print(f'sample example for string variable where the value is:\n {string_char}'

More examples

# another example where we can pass more than one object
print('Guido van Rossum','created Python', 'in December 1989')
# output : Guido van Rossum created Python in December 1989
# or we can pass in variable
who = 'Guido van Rossum'
what = 'created Python'
when = 'in December 1989'
print(who,what,when)
# output : Guido van Rossum created Python in December 1989