Strip Methods
Strip Methods
name1 = " Xtra "
name2 = "Coding"
print(name1 + name2)
print(name1.lstrip() + name2) # Removes left side spaces
print(name1.rstrip() + name2) # Removes right side spaces
print(name1.strip() + name2) # Removes both side spaces
Post a Comment