- lstrip() is a python in-build function which are used to delete the specified content at the left side of the string
- it take one string as an argument which we want to remove from the left portion of the given string.
Syntax-
str.lstrip(chars)
Example
string is s="this is string"
and s.lstrip("this") will return "is string"
program-
s="This is string"
print(s.lstrip('This'))
s="11111111111mgs"
print(s.lstrip('1'))
s="-----this is string-------"
print(s.lstrip("-"))
s="-----this is string-------"
print(s.lstrip("this"))
is string
mgs
this is string-------
-----this is string-------