代码示例:(标识:python_ref_file_tell_1)
python_ref_file_tell_1.py
f = open("demofile.txt", "r")
print(f.tell())
运行结果: