For example I want to take input the absolute path from the user like "C:\Users\User\Desktop" and change it to "C:\\Users\\User\\Desktop" but when I do the following:
path = input("Enter path: ")
and
path = path.replace("\", "\\")
it throws syntax error as the escape sequence of \\
is triggered. How do I bypass this and achieve the replace?
Correction: It takes input and adjusts itself! There is no need to do such a thing as mentioned above...