From e07e2445bfe5757bf27f7e98f36a9332eb7ccdf9 Mon Sep 17 00:00:00 2001 From: Victor Alexandrovich Tsyrenschikov <77172321+tsyrenschikov@users.noreply.github.com> Date: Tue, 3 Mar 2026 12:51:17 +0500 Subject: [PATCH] 8 --- 8.py | 15 +++++++++------ f.py | 10 ++++++---- 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/8.py b/8.py index 72d8335..01d721e 100644 --- a/8.py +++ b/8.py @@ -13,10 +13,13 @@ from timeit import repeat # from itertools import product # print([''.join(p) for p in product('ЛНРТ', repeat=5)][149]) -a=0 -collec=sorted(list(''.join(i) for i in product('СДАЙЕГЭ', repeat=6))) -for i in range(len(collec)): - # if 'ЕГЭ' in collec[i]: - if collec[i].count('ЕГЭ'): - a+=i+1 +# a=0 +# collec=sorted(list(''.join(i) for i in product('СДАЙЕГЭ', repeat=6))) +# for i in range(len(collec)): +# # if 'ЕГЭ' in collec[i]: +# if collec[i].count('ЕГЭ'): +# a+=i+1 +# print(a) +from itertools import product +a=[i for i in product([i for i in range(20)],repeat = 5)] print(a) \ No newline at end of file diff --git a/f.py b/f.py index 87fb58c..c51fead 100644 --- a/f.py +++ b/f.py @@ -1,4 +1,6 @@ -a=list(map(int,input().split())) -for i in range(len(a)): - if a[i]%2==0: - print(a[i]) \ No newline at end of file +students = [["Alice", [5, 4, 4, 5]],["Bob", [3, 4, 4, 3]],["Charlie", [5, 5, 5, 4]]] + +c=[] +for student in range(len(students)): + c.append(sum(students[student][1])/len(students[student][1])) +print('Максимальный балл: ',students[c.index(max(c))][0],'',max(c)) \ No newline at end of file