Python has join and Os.path.join () two functions, which work as follows:
Join: An array of connection strings. Generates a new string from a string, tuple, or element in the list, with the specified character (delimiter) connection
Os.path.join (): Combine multiple paths to return
First, function description
1.join () function
Syntax: ' Sep '. Join (SEQ)
Parameter description:
Sep: Delimiter. Can be empty
SEQ: sequence of elements to concatenate, strings, tuples, dictionaries, etc.
The syntax above is to combine all the SEQ elements into a new string with Sep as a delimiter
Return value: Returns a string that is generated after each element is concatenated with the delimiter Sep
2. Os.path.join () function
Syntax: Os.path.join (path1[,path2[,......])
Return value: Combine multiple paths to return
Note: Parameters before the first absolute path are ignored
Join functions and os.path.join usages in Python