How do I create a column that starts from "\"" and ends in "]" in another column?
For example
A new_column
\\loc\ggg.x]ddj \\loc\ggg.x]
+\\lol\lll.d]aaa \\lol\lll.d]
I tried doing this
df['new_column'] = df['A'].str.split(']').str[0]
but it included unneeded text and want to only start at X (\) and end with Y ("]").