[Tutor] path

Mats Wichmann mats at wichmann.us
Sat Jun 29 09:52:32 EDT 2019


Sigh... something dropped my raw string, so that was a really bad sample :(

inp = r"c:\test\drive\this"


On Sat, Jun 29, 2019, at 07:44, Mats Wichmann wrote:
> 
> For your example, when you define inp as a string, it needs to be a raw
> string because otherwise Python will interpret the backslash sequences.
> \t means tab, which is why the the results look mangled.
> 
> inp = "c:\test\drive\this"
> 
> 


More information about the Tutor mailing list