Looping Over Characters with read : File Read : File PYTHON examples


PYTHON examples » File » File Read »

 

Looping Over Characters with read



f = open("fileName")
char = f.read(1)
while char:
    process(char)
    char = f.read(1)

f.close()
           
       



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON examples

 Navioo File
» File Read