SORU
24 Mart 2010, ÇARŞAMBA


dosya boş kontrol etmek için python ya da değil

Bir metin dosyası var. Nasıl dosya boş veya boş olup olmadığını kontrol edebilir miyim?

CEVAP
24 Mart 2010, ÇARŞAMBA


import os    
os.path.getsize(fullpathhere) > 0

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • Epic Tutorials for iPhone, iPad and iOS

    Epic Tutoria

    18 EYLÜL 2011
  • HSmasteryoda .

    HSmasteryoda

    22 Ocak 2010
  • MatheusDosGames

    MatheusDosGa

    28 Aralık 2011