Zadanie 5

This commit is contained in:
Justyna Adamczyk 2018-06-02 10:12:33 +00:00
parent 58cef93540
commit d612367edb

21
labs04/Zadanie 5 Normal file
View File

@ -0,0 +1,21 @@
import glob
sciezka = 'scores/*.npz.bleu'
for plik in glob.glob(sciezka):
with open(plik, 'r') as f:
for linia in f.readlines():
numer = float(linia[linia.find("=") + 1:linia.find(",")])
if numer > 0:
max_numer = numer
max_numer_plik = plik
f.close()
print(max_numer_plik)