diff options
author | Santo Cariotti <sancn@live.com> | 2017-05-02 09:17:26 +0200 |
---|---|---|
committer | Santo Cariotti <sancn@live.com> | 2017-05-02 09:17:26 +0200 |
commit | 372d5d65493bc117e5cf642cc5e703cfab0a278f (patch) | |
tree | fd036c07897007b0b1bcfd2f5cbbd933809eb109 | |
parent | 0529cbf6f276b769022c0cd50b006b8de99c9383 (diff) |
Righe del file indefinite
-rw-r--r-- | python/crittografa.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/python/crittografa.py b/python/crittografa.py index f853527..f629d13 100644 --- a/python/crittografa.py +++ b/python/crittografa.py @@ -21,8 +21,11 @@ def converti(lettera): else: nuovaParola.append(lettera) +parole = '' + with open('input.txt', 'r') as fin: - parole = fin.read(999999) + for line in fin.readlines(): + parole += line for i in parole: @@ -31,4 +34,4 @@ for i in parole: with open('output.txt', 'w') as fout: for i in nuovaParola: - fout.write(i)
\ No newline at end of file + fout.write(i) |