Python - Concatenation of strings

In this program, you will learn how to do the concatenation of two strings values.


Program Code



    # Concatenation of strings
    x = "I'm Learing "
    y = "Python!!"
    z = x + y
    
    print(z)

Output



    I'm Learing Python!!

In this program, the variables x and y are having the string values. To concat x and y values, you can use + operator and assign this result to z variable to print it.

In this program, x value is 'I'm Learning ' and y value is 'Python!!'. The result will be 'I'm Learning Python!!.

The following topics can be useful to understand this program.



Related Tutorials