45672023-03-29 22:23:57DohajovDanielKert (75 pont)python3Wrong answer 55/75379ms67428 KiB
def main():
    sdb,vdb,szk=[int(i) for i in input().split()]
    sorL=[];db=0;mxe=0;tobbdb=0
    for s in range(sdb):
        sorL.append([int(i) for i in input().split()])
        most=0
        for b in range(vdb):
            if mxe<db: mxe=db
            if most==sorL[s][b]:
                db+=1
            else: most=sorL[s][b]; db=1
        sorL[s].sort()
        db=0;most=0;
        for b in range(vdb):
            if sorL[s][b]==most:
                db+=1
            else: 
                if vdb/2<db:
                    tobbdb+=1;db=1
                    break
                most=sorL[s][b]; db=1
    print(tobbdb)
    print(mxe)
main()
""" 
4 7 9
2 1 2 3 8 2 2
4 7 2 4 9 7 4
5 5 2 5 5 5 7
2 3 2 3 2 3 1
"""

SubtaskSumTestVerdictTimeMemory
base55/75
1Accepted0/018ms11180 KiB
2Accepted0/0379ms52844 KiB
3Wrong answer0/417ms11592 KiB
4Accepted4/417ms11580 KiB
5Partially correct2/417ms11652 KiB
6Wrong answer0/417ms11772 KiB
7Accepted4/417ms11960 KiB
8Wrong answer0/417ms12112 KiB
9Accepted4/417ms12216 KiB
10Accepted4/424ms13300 KiB
11Accepted6/618ms12708 KiB
12Accepted6/630ms14512 KiB
13Accepted6/659ms17788 KiB
14Accepted6/6375ms53636 KiB
15Runtime error0/6337ms67428 KiB
16Accepted6/6370ms54408 KiB
17Accepted7/7199ms34436 KiB