def Join(List, sep=None):
def Join(List, sep=None):
result = '' # Initialize an empty string to store the result
# Iterate through the list of strings
for i in range(len(List)):
# Append the current string to the result
result += List[i]
# If there is a separator, append it as well.
if sep and i < len(List)-1:
result += sep
return result
免责声明:
以上内容除特别注明外均来源于网友提问,创作工场回答,未经许可,严谨转载。