isfile and isdir - test if the path is a file or directory, respectively. Example: import os.path print os.path.isfile("c:/Windows") print os.
確定! 回上一頁