SyntaxFix
Write A Post
Hire A Developer
Questions
You can simply use list comprehension.
Assume that you have the string: my name is and you want to remove character m. use the following code:
my name is
m
"".join([x for x in "my name is" if x is not 'm'])