Submission #764059

# Submission time Handle Problem Language Result Execution time Memory
764059 2023-06-23T06:24:01 Z rithikkatyal Programming Contest (POI11_pro) Python 3
0 / 100
290 ms 6476 KB
n,m,r,t,k = map(int,input().split())
X = [None]* n

for _ in range(k):
    u,v = map(int,input().split())
    if(X[u-1] == None):
        X[u-1] = [v]
    else:
        X[u-1].append(v)


max_level = 0
for i in X:
    if i != None:
        max_level = max(max_level,len(i))

tc = 0
solved = set()
answers = []
for level in range(max_level):
    for j in range(len(X)):
        if(X[j] != None and level < len(X[j])):
            if(X[j][level] not in solved):
                tc += (r + (level * r))
                solved.add(X[j][level])
                answers.append([j+1,X[j][level],level * r])
print(len(solved),tc)  
for item in answers:
    print(*item,end=' ')      
    print()
# Verdict Execution time Memory Grader output
1 Incorrect 15 ms 2960 KB It was possible to get penalty of 20418000 points and you received 114476920.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 14 ms 2900 KB It was possible to get penalty of 55643980 points and you received 110493046.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 18 ms 2964 KB It was possible to get penalty of 72329760 points and you received 664529670.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 56 ms 3008 KB It was possible to get penalty of 5478600 points and you received 171425394.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 200 ms 5480 KB Expected int32, but "18327345921" found
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 163 ms 4888 KB Expected int32, but "12632882911" found
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 290 ms 6476 KB Expected int32, but "34607620596" found
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 58 ms 3444 KB Your program assigned 489 problems but it was possible to solve only 390.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 169 ms 4992 KB It was possible to get penalty of 500 points and you received 31420.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 65 ms 3712 KB Your program assigned 458 problems but it was possible to solve only 452.
2 Halted 0 ms 0 KB -