Remove 'joined' from a String in Python
To remove the word 'joined' from the string, you can use the replace() method in Python. Here's an example:
string = 'Joined October 2018'
new_string = string.replace('joined', '')
print(new_string)
Output:
October 2018
In this code, we use the replace() method to replace the word 'joined' with an empty string, effectively removing it from the original string.
原文地址: https://www.cveoy.top/t/topic/pBX5 著作权归作者所有。请勿转载和采集!