python os.path.sep
来源:互联网 发布:app建站 编辑:程序博客网 时间:2024/05/19 10:35
python中os.path常用模块
os.path.sep:路径分隔符 linux下就用这个了’/’
os.path.altsep: 根目录
os.path.curdir:当前目录
os.path.pardir:父目录
os.path.abspath(path):绝对路径
os.path.join(): 常用来链接路径
os.path.split(path): 把path分为目录和文件两个部分,以列表返回
- [GCC 4.4.5] on linux2
- Type "help", "copyright", "credits" or "license" for more information.
- >>> import os
- >>> help('os.path.sep')
- >>> print os.path.sep
- /
- >>> print os.path.altsep
- None
- >>> print os.path.curdir
- .
- >>> print os.path.abspath('/root')
- /root
- >>> print os.path.abspath('/root/pp')
- /root/pp
- >>> print os.path.abspath('/root/pp/f.c')
- /root/pp/f.c
- >>> print os.path.split('/root/pp/f.c')
- ('/root/pp', 'f.c')
- >>>
0 0
- python os.path.sep
- 学习python[4] python os.path.sep
- Python os.path模块
- Python os.path模块
- python os.path
- [python] os.path模块
- python os.path模块
- Python os.path模块
- Python os.path模块
- python os.path模块
- Python os.path模块
- python os.path模块
- Python os.path模块
- python os.path模块
- Python os.path模块
- python os.path模块
- Python os.path模块
- python os.path
- Oracle EBS Form Trigger学习大全
- 怎么获得pb数据窗口中的所有列的名字,包括不显示的列
- html/jsp有些别的电脑不可以显示
- HTML:介绍几个不常用的HTML标签
- 如何用CSS控制图片自适应大小的方法
- python os.path.sep
- leetcode_题解_Maximum Depth of Binary Tree_简单题
- UITextField键盘点击实现登录效果
- C++2005调用C#Webservice接口返回值为List
- oracle-12514错误
- 使用swingbench实现oracle数据库压力测试
- Android 4.0.3 CTS 测试
- 为什么Lisp语言如此先进?
- 操作数组