enochmeng

os.open()返回为打开文件的描述符

f = os.open("test2.py", os.O_NONBLOCK)
print f # 结果为3

 

open()返回为文件对象

f = open("test.log", "wb")
print f # 结果为<open file \'test.log\', mode \'wb\' at 0x0000000002835030>

详细介绍open():http://www.runoob.com/python/python-func-open.html

分类:

技术点:

相关文章:

  • 2021-08-28
  • 2022-12-23
  • 2022-12-23
  • 2021-10-16
  • 2022-12-23
  • 2021-08-01
  • 2022-01-12
  • 2022-01-11
猜你喜欢
  • 2021-09-13
  • 2021-10-25
  • 2022-12-23
  • 2022-12-23
  • 2021-05-16
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案