Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

join two strings python

var1 = "Hello"
var2 = "World"
 
# join() method is used to combine the strings
print("".join([var1, var2]))
 
# join() method is used here to combine
# the string with a separator Space(" ")
var3 = " ".join([var1, var2])
 
print(var3)
Source by www.geeksforgeeks.org #
 
PREVIOUS NEXT
Tagged: #join #strings #python
ADD COMMENT
Topic
Name
5+6 =