import os
with open(‘test_file’,‘wb’) as f:
while os.path.getsize(‘test_file’) <= 56000000:
f.write(b’xxxxxxx’)
# f.write(b’xxxxx’ * 100)
print(os.path.getsize(‘test_file’))
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/215748.html
標籤:python
上一篇:按奇偶排序陣列 II
