![]() |
sponsored links |
|
|
sponsored links
|
|
21
18th December 00:15
External User
Posts: 1
|
You mean like this:
import os os.path.sep + os.path.split(r"c:\dos\util")[-1] -- Robert Kern rkern@ucsd.edu "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter |
|
|
|
22
18th December 00:22
External User
Posts: 1
|
Did you actually look at the docs Fredrik pointed you at? Did you,
in particular, notice os.path.basename, which does (almost) exactly what you want? -- \S -- siona@chiark.greenend.org.uk -- http://www.chaos.org.uk/~sion/ ___ | "Frankly I have no feelings towards penguins one way or the other" \X/ | -- Arthur C. Clarke her nu becomež se bera eadward ofdun hlęddre heafdes bęce bump bump bump |
|
|