buggy
stringlengths
1
618k
fixed
stringlengths
16
618k
buggy_submission_id
stringlengths
10
10
fixed_submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
lang
stringclasses
1 value
buggy_verdict
stringclasses
2 values
n = int(input()) a = [[] for i in range(n)] for i in range(n): v = list(map(int, input().split())) u = v[0] - 1 for j in v[2:]: a[u].append(j-1) d = [0] * n isDiscovered = [False] * n def bfs(x): global time_stamp time_stamp += 1 for i in a[x]: if not isDiscovered[i]: ...
n = int(input()) a = [[] for i in range(n)] for i in range(n): v = list(map(int, input().split())) u = v[0] - 1 for j in v[2:]: a[u].append(j-1) d = [-1] * n isDiscovered = [False] * n def bfs(x): for i in a[x]: if not isDiscovered[i]: isDiscovered [i] = True d...
s712352296
s965393676
p02239
python
Runtime Error
n = int(input()) a = [[] for i in range(n)] for i in range(n): v = list(map(int, input().split())) u = v[0] - 1 for j in v[2:]: a[u].append(j-1) d = [0] * n isDiscovered = [False] * n def bfs(x): for i in a[x]: if not isDiscovered[i]: isDiscovered [i] = True d[...
n = int(input()) a = [[] for i in range(n)] for i in range(n): v = list(map(int, input().split())) u = v[0] - 1 for j in v[2:]: a[u].append(j-1) d = [-1] * n isDiscovered = [False] * n def bfs(x): for i in a[x]: if not isDiscovered[i]: isDiscovered [i] = True d...
s265885753
s965393676
p02239
python
Time Limit Exceeded
n, m = map(int, input().split()) a = [[False]*n for i in range(n)] rootList = [-1] * n def hasSameRoot(x, y): if rootList[x] == rootList[y] != -1: return True elif rootList[x] == x and rootList[y] == y: return False elif x > 1: return hasSameRoot(y, x-1) else: return has...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s788513410
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1] * n def getRoot(x): if rootList[x] < 0: return x rootList[x] = getRoot(rootList[x]) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: G[x], G[y] = min(x, y), min(x, y) for i in range(0, m): s...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s146986224
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1] * n def getRoot(x): if rootList[x] < 0: return x rootList[x] = getRoot(rootList[x]) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: G[x], G[y] = min(x, y), min(x, y) for i in range(m): s, t...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s190883380
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1] * n def getRoot(x): if rootList[x] < 0: return x return getRoot(rootList[x]) def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: G[x], G[y] = min(x, y), min(x, y) for i in range(m): s, t = map(int, input().split()) ...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s726165331
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1] * n def getRoot(x): if rootList[x] < 0: rootList[x] = x return x return getRoot(rootList[x]) def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x], rootList[y] = min(x, y), min(x, y) for i in range...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s842876680
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1] * n def getRoot(x): if rootList[x] < 0: rootList[x] = x return x return getRoot(rootList[x]) def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x], rootList[y] = min(x, y), min(x, y) for i in range...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s027169896
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): if rootList[x] < 0: rootList[x] = x return x return getRoot(rootList[x]) def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x], rootList[y] = min(x, y), min(x, y) ...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s633037213
s344753766
p02240
python
Runtime Error
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
n, m = map(int, input().split()) rootList = [-1 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] def setSameRoot(x, y): x = getRoot(x) y = getRoot(y) if x != y: rootList[x] = ro...
s324710339
s344753766
p02240
python
Runtime Error
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(i): if a[j] != -1: edgeList.append([a[j], getRoot(i), getRoot(j)]) rootList = [-1 for i in range(n)] sumLength = 0 def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x ...
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(i): if a[j] != -1: edgeList.append([a[j], i, j]) rootList = [-1]*n sumLength = 0 def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x...
s730296013
s701818625
p02241
python
Runtime Error
n = int(input()) edgeList = [] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] for i in range(n): a = list(map(int, input().split())) for j in range(i): if a[j] != -1: edgeList.appen...
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(i): if a[j] != -1: edgeList.append([a[j], i, j]) rootList = [-1]*n sumLength = 0 def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x...
s709238810
s701818625
p02241
python
Runtime Error
rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [0 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] edgeList.sort(key=lambda x: x[0]) flag = True while flag: flag = Fals...
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(a[1]): edgeList.append([a[2*j+3], i, a[2*j+2]]) rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [float("inf") for i in range(n)] lenList[0] = 0 def getRoot(x): r = root...
s425467275
s510088962
p02242
python
Runtime Error
rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [0 for i in range(n)] def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] edgeList.sort(key=lambda x: x[0]) flag = True while flag: flag = Fals...
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(a[1]): edgeList.append([a[2*j+3], i, a[2*j+2]]) rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [float("inf") for i in range(n)] lenList[0] = 0 def getRoot(x): r = root...
s237321306
s510088962
p02242
python
Runtime Error
rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [float("inf") for i in range(n)] lenList[0] = 0 def getRoot(x): r = rootList[x] if r < 0: rootList[x] = x elif r != x: rootList[x] = getRoot(r) return rootList[x] flag = True while flag: flag = False edge...
n = int(input()) edgeList = [] for i in range(n): a = list(map(int, input().split())) for j in range(a[1]): edgeList.append([a[2*j+3], i, a[2*j+2]]) rootList = [-1 for i in range(n)] parent = [0 for i in range(n)] lenList = [float("inf") for i in range(n)] lenList[0] = 0 def getRoot(x): r = root...
s776819136
s510088962
p02242
python
Runtime Error
n = int(input()) S = list(input().split()) q = input() T = input().split() count = 0 for key in T: U = S + [key] i = 0 while U[i] != key: i = i+1 if i != n: count = count + 1 print(count)
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s099986692
s760565208
p02268
python
Time Limit Exceeded
n = int(input()) S = map(int, input().split()) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right mid = (right - left) // 2 if S[mid] == key: count = count + 1 break else if key < S[mid] r...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s547683412
s760565208
p02268
python
Runtime Error
n = int(input()) S = map(int, input().split()) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right mid = (right - left) // 2 if S[mid] == key: count = count + 1 break else if key < S[mid]: ...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s003251588
s760565208
p02268
python
Runtime Error
n = int(input()) S = map(int, input().split()) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right: mid = (right - left) // 2 if S[mid] == key: count = count + 1 break else if key < S[mid]: ...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s248978974
s760565208
p02268
python
Runtime Error
n = int(input()) S = map(int, input().split()) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right: mid = (right - left) // 2 if S[mid] == key: count = count + 1 break elif key < S[mid]: ri...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s855367625
s760565208
p02268
python
Runtime Error
n = int(input()) S = map(int, input().split()) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right: mid = (right - left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: righ...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s071374058
s760565208
p02268
python
Runtime Error
count = 0 for key in T: left = 0 right = n while left < right: mid = (right - left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: right = mid else: left = mid + 1 print(count)
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s439255544
s760565208
p02268
python
Runtime Error
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = map(int, input().split()) count = 0 for key in T: left = 0 right = n while left < right: mid = (right - left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
n = int(input()) S = list(map(int, input().split())) q = int(input()) T = list(map(int, input().split())) count = 0 for key in T: left = 0 right = n while left < right: mid = (right + left) // 2 if S[mid] == key: count = count + 1 break if key < S[mid]: ...
s539177306
s760565208
p02268
python
Time Limit Exceeded
n = int(sys.stdin.readline()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m): if m == 0: return True elif i >= n: return False res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res for m in M: if solve(0, m): ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s819040341
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m): if m == 0: return True elif i >= n: return False res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res for m in M: if solve(0, m): print('yes')...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s650152626
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m, A): if m == 0: return True elif i >= n: return False res = solve(i + 1, m, A) or solve(i + 1, m - A[i], A) return res for m in M: if solve(0, m, A): ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s475141969
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m): if m == 0: return True elif i >= n: return False res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res for m in M: if solve(0, m): print('yes')...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s468133004
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m): if m == 0: return True elif i >= n: return False else: res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res for m in M: if solve(0, m): ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s610525500
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[]*n]*max(M) def solve(i, m): if m == 0: return True elif i >= n: return False else: res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res for m in M: ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s731407814
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0]*max(M)]*n def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] else: res = solve(i + 1, m) or s...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s239572457
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(max(M))] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] else: ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s569322393
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(n)] for j in range(max(M))] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] else: ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s569567002
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(n)] for j in range(max(M)+1)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] else: ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s360084446
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] else: ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s029874904
s981302488
p02271
python
Runtime Error
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n or m < 0: return False elif table[i][m] != 0: return table[i][m] ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s327707853
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) def solve(i, m): if m == 0: return True elif i >= n: return False elif m - A[i] >= 0: res = solve(i + 1, m) or solve(i + 1, m - A[i]) return res else: res =...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s766230647
s981302488
p02271
python
Time Limit Exceeded
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[0 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != 0: return table[i][m] elif m ...
n = int(input()) A = list(map(int, input().split())) q = int(input()) M = list(map(int, input().split())) table = [[-1 for i in range(max(M)+1)] for j in range(n)] def solve(i, m): if m == 0: return True elif i >= n: return False elif table[i][m] != -1: return table[i][m] elif ...
s540966549
s981302488
p02271
python
Time Limit Exceeded
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '') preorder(left[i]) ...
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) - N - 1 for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '', end = '') preo...
s763315419
s726786056
p02281
python
Runtime Error
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) - N - 1 for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '') preorder(left[...
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) - N - 1 for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '', end = '') preo...
s557881967
s726786056
p02281
python
Runtime Error
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) - N - 1 for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '', end = '') preo...
N = int(input()) left = [-1 for i in range(N)] right = [-1 for i in range(N)] root = sum(range(N)) - N - 1 for i in range(N): i, l, r = map(int, input().split()) left[i] = l right[i] = r root -= (l + r) def preorder(i): if i == -1: return print(' ', i, sep = '', end = '') preo...
s303939197
s726786056
p02281
python
Runtime Error
v, e, r = list(map(int, input().split())) edgeList = [[0, 0, 0] for i in range(e)] rootList = [-1 for i in range(v)] parent = [-1 for i in range(v)] lenList = [0 for i in range(v)] for i in range(e): a = list(map(int, input().split())) edgeList[e] = [a[2], a[0], a[1]] rootList = [-1 for i in range(n)] pare...
from heapq import heappush, heappop V, E, s = map(int, input().split()) Adj = [[] for i in range(V)] for i in range(E): ui, vi, ci = map(int, input().split()) Adj[ui].append([vi, ci]) d = [float("inf")] * V d[s] = 0 pq = [[0, s]] fixed = 0 while pq: di, v = heappop(pq) if di > d[v]: continue...
s045257157
s013923861
p02361
python
Runtime Error
v, e, r = list(map(int, input().split())) edgeList = [[0, 0, 0] for i in range(e)] for i in range(e): a = list(map(int, input().split())) edgeList[i] = [a[2], a[0], a[1]] rootList = [-1 for i in range(v)] parent = [0 for i in range(v)] lenList = [float("inf") for i in range(v)] lenList[r] = 0 def getRoot(x)...
from heapq import heappush, heappop V, E, s = map(int, input().split()) Adj = [[] for i in range(V)] for i in range(E): ui, vi, ci = map(int, input().split()) Adj[ui].append([vi, ci]) d = [float("inf")] * V d[s] = 0 pq = [[0, s]] fixed = 0 while pq: di, v = heappop(pq) if di > d[v]: continue...
s971595967
s013923861
p02361
python
Time Limit Exceeded
while True: x = list(map(int, input().split())) if x == y == 0: break print(min(x), max(x))
while True: x = list(map(int, input().split())) if x[0] == x[1] == 0: break print(min(x), max(x))
s954986899
s706779905
p02397
python
Runtime Error
while True: a, op, b = input().split() a, b = int(a), int(b) if op == '?': break elif op == '+': print(a+b) elif op == '-': print(a-b) elif op == '*': print(a*b) elif op == '/': print(a//b)
import math r = float(input()) print(r*r*math.pi, 2*r*math.pi)
s233433416
s882462913
p02400
python
Runtime Error
import math r = int(input()) print(2*r*math.pi, r*r*math.pi)
import math r = float(input()) print(r*r*math.pi, 2*r*math.pi)
s989197867
s882462913
p02400
python
Runtime Error
a, b = map(int,input().split()) A = [[]*b for i in range(a)] B = [] * b for i in range(a): A[i] = map(int,input().split()) for i in range(b): B[i] = int(input()) for i in range(a): s=0 for j in range(b): s+=A[i][j]*B[j] print(s)
a, b = map(int,input().split()) A = [[0]*b for i in range(a)] B = [0] * b for i in range(a): A[i] = list(map(int,input().split())) for i in range(b): B[i] = int(input()) for i in range(a): s=0 for j in range(b): s+=A[i][j]*B[j] print(s)
s276545985
s927020744
p02410
python
Runtime Error
#coding:utf-8 a, b = map(int, raw_input(). split()) print(a * b / 3.305785)
#coding:utf-8 a, b = map(int, raw_input(). split()) print(a * b / 3.305785)
s239458231
s341369193
p00094
python
Runtime Error
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
s699057023
s246724913
p00254
python
Runtime Error
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
s680197885
s246724913
p00254
python
Runtime Error
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
s935565040
s246724913
p00254
python
Runtime Error
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
while True: n = input() if n == "0000": break if n.count(n[0]) == 4: print("NA") continue cnt = 0 while n != "6174": n, l = sorted(list(n)), sorted(list(n), reverse=True) n = str(int("".join(l)) - int("".join(n))).zfill(4) cnt += 1 print(cnt)
s008812140
s246724913
p00254
python
Runtime Error
a = [False for i in range(31)] for i in range(30): x = int(input()) a[x] = True for i in range(1, 30): if a[i] == False: print(i)
a = [False for i in range(30)] for i in range(28): a[int(input()) - 1] = True for i in range(30): if a[i] is False: print(i + 1)
s915608709
s374110191
p00434
python
Runtime Error
while True: s = input() if s == "": break joi = 0 ioi = 0 for i in range(len(s) - 2): x = s[i] + s[i + 1] + s[i + 2] if (x == "JOI"): joi += 1 elif (x == "IOI"): ioi += 1 print(joi) print(ioi)
while True: try: s = input() except: break joi = 0 ioi = 0 for i in range(len(s) - 2): x = s[i] + s[i + 1] + s[i + 2] if x == "JOI": joi += 1 if x == "IOI": ioi += 1 print(joi) print(ioi)
s001373565
s345359191
p00445
python
Runtime Error
while True: s = input() if s == "": break joi = 0 ioi = 0 s_list = [s[i:i+3] for i in range(len(s) - 2)] for i in s_list: if i == "JOI": joi += 1 if i == "IOI": ioi += 1 print(joi) print(ioi)
while True: try: s = input() except: break joi = 0 ioi = 0 for i in range(len(s) - 2): x = s[i] + s[i + 1] + s[i + 2] if x == "JOI": joi += 1 if x == "IOI": ioi += 1 print(joi) print(ioi)
s389894781
s345359191
p00445
python
Runtime Error
count = 0 a = int(input()) a, b, c, d, e = map(int, input(). split()) list1 = [a ,b, c, d, e] for i in range(len(list1)): for n in range(len(list1) - i - 1): if(list1[n] > list1[n + 1]): tmp = list1[n] list1[n] = list1[n + 1] list1[n + 1] = tmp count += 1 for i in range(len(list1)): p...
count = 0 list1 = [] a = int(input()) list1 = list(map(int, input(). split())) for i in range(len(list1)): for n in range(len(list1) - i - 1): if(list1[n] > list1[n + 1]): tmp = list1[n] list1[n] = list1[n + 1] list1[n + 1] = tmp count += 1 print(" ".join(str(x) for x in list1)) print(...
s603331463
s903116882
p02259
python
Runtime Error
a=map(int,input().split()) a.sort() for i in range(3): print(a[i]),
a = map(int ,raw_input(). split()) a.sort() for i in range(3): print(a[i]),
s949046186
s184147858
p02393
python
Runtime Error
import sys import math for line in sys.stdin: a = line.split() if len(a) == 3: if int(a[0])*int(a[0]) + int(a[1])*int(a[1]) == int(a[2])*int(a[2]): print("YES") else: print("NO") }else{ console.log("NO") } } });
import sys import math for line in sys.stdin: a = line.split() if len(a) == 3: if (int(a[0])*int(a[0]) + int(a[1])*int(a[1])) == int(a[2])*int(a[2]) or (int(a[0])*int(a[0]) + int(a[2])*int(a[2])) == int(a[1])*int(a[1]) or (int(a[2])*int(a[2]) + int(a[1])*int(a[1])) == int(a[0])*int(a[0]): print("Y...
s594182699
s533704034
p00003
python
Runtime Error
import math num = int(input) print(math.factorial(num))
import math num = int(input()) print(math.factorial(num))
s740882874
s494971535
p00019
python
Runtime Error
import math num = int(input()) for i in range(num): ax,ay,ar,bx,by,br = map(float,input().split(' ')) d = (ax - bx)*(ax - bx) + (ay * by) if d < abs(br - ar): if ar > br: print(2) else: print(-2) elif d <= r1 + r2: print(1) else: print(0)
import math num = int(input()) for i in range(num): ax,ay,ar,bx,by,br=map(float,input().split()) d = ((ax-bx)* (ax - bx))+((ay-by)*(ay-by)) r1 = (ar+br)*(ar+br) r2 = (ar-br)*(ar-br) if d <= r1 and d >= r2: print(1); elif d<r2 and ar>=br: print(2) elif d < r2 and ar <= br:...
s116208847
s853368534
p00023
python
Runtime Error
import math num = int(input()) for i in range(num): ax,ay,ar,bx,by,br = map(float,input().split(' ')) d = (ax - bx)*(ax - bx) + (ay * by)(ay * by) if d < abs(br - ar): if ar > br: print(2) else: print(-2) elif d <= ar + br: print(1) else: ...
import math num = int(input()) for i in range(num): ax,ay,ar,bx,by,br=map(float,input().split()) d = ((ax-bx)* (ax - bx))+((ay-by)*(ay-by)) r1 = (ar+br)*(ar+br) r2 = (ar-br)*(ar-br) if d <= r1 and d >= r2: print(1); elif d<r2 and ar>=br: print(2) elif d < r2 and ar <= br:...
s650111539
s853368534
p00023
python
Runtime Error
import math def lenPrimeNumber(num): if num == 1: return 1 else: sList = list(range(2, num + 1)) pList = [] while sList[0] < math.sqrt(num): pList.append(sList.pop(0)) sList = list(filter(lambda x: x % pList[-1] != 0, sList)) pList.extend(sList) return len(list(map(lambda x: num % x == 0, pList)))...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s816081170
s451726157
p00009
python
Time Limit Exceeded
import sys; import math; lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < math.ceil(math.sqrt(line)) + 1 : pList.append(sList.pop()) for p in pList: sList...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s375475650
s451726157
p00009
python
Runtime Error
import sys import math lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < math.ceil(math.sqrt(line)) + 1 : pList.append(sList.pop()) for p in pList: sList =...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s075684022
s451726157
p00009
python
Runtime Error
import sys import math lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < int(math.ceil(math.sqrt(line))) + 1 : pList.append(sList.pop()) for p in pList: sL...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s437799286
s451726157
p00009
python
Runtime Error
import sys import math lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < int(math.ceil(math.sqrt(line))) + 1: pList.append(sList.pop()) for p in pList: sLi...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s606762120
s451726157
p00009
python
Runtime Error
import sys import math lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < (int(math.ceil(math.sqrt(line))) + 1): pList.append(sList.pop()) for p in pList: s...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s211159804
s451726157
p00009
python
Runtime Error
import sys import math lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) pList = [] sList = list(reversed(list(range(3, line + 1))[::2])) while sList[-1] < int(math.ceil(math.sqrt(line))) + 1: pList.append(sList.pop()) for p in pList: sLi...
import sys import math LIMIT = 1000000 p = 2 pList = [True] * (LIMIT + 1) while p ** 2 <= LIMIT: if(pList[p]): for i in range(p * 2, LIMIT + 1 , p): pList[i] = False p += 1 # print(pList) lines = str(sys.stdin.read()).strip().split("\n") for line in lines: line = int(line) co...
s343807149
s451726157
p00009
python
Runtime Error
n = input() for i in range(n): a,b,c = map(int, input().split()) if a*a+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a: print("YES") else: print("NO")
n = int(input()) for i in range(0, n): a,b,c = map(int, input().split()) if a*a+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a: print("YES") else: print("NO")
s810354926
s800969632
p00003
python
Runtime Error
n = input() for i in range(0, n): a,b,c = map(int, input().split()) if a*a+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a: print("YES") else: print("NO")
n = int(input()) for i in range(0, n): a,b,c = map(int, input().split()) if a*a+b*b==c*c or a*a+c*c==b*b or b*b+c*c==a*a: print("YES") else: print("NO")
s619677037
s800969632
p00003
python
Runtime Error
n = int(input()) result = 100000 for i in range(0,n): result = result * 1.05 if result % 1000 == 0: pass else: result = result-(result % 1000)+ 1000 result = result(int) print(result)
n = int(input()) result = 100000 for i in range(0,n): result = result * 1.05 if result % 1000 == 0: pass else: result = result-(result % 1000)+ 1000 result = int(result) print(result)
s323750497
s025674646
p00007
python
Runtime Error
try: while True: result = result2 = count = 0 a, b = map(int, input().split(',')) result += a*b result2 += b count += 1 except: print(result,"{0:.1f}".format(result2/count))
try: result = result2 = count = 0 while True: a, b = map(int, input().split(',')) result += a*b result2 += b count += 1 except: print(result) print(round(result2/count+0.5))
s592007717
s138536196
p00045
python
Runtime Error
try: result = result2 = count = 0 while True: a, b = map(int, input().split(',')) result += a*b result2 += b count += 1 except: print(result) print((round(result2/count+0.5))
try: result = result2 = count = 0 while True: a, b = map(int, input().split(',')) result += a*b result2 += b count += 1 except: print(result) print(round(result2/count+0.5))
s491180005
s138536196
p00045
python
Runtime Error
import re try: ls = num = [] result = 0 while True: ls.append(input()) except: for i in ls: for s in range(re.findall(r'\d+', i)): result += int(s) print(result)
import re try: result = 0 while True: for s in re.findall(r'\d+', input()): result += int(s) except: print(result)
s759687004
s428613397
p00064
python
Runtime Error
ls = list(map(int, input().split())) ls.sort() if ls[0]==ls[1]==ls[2]==ls[3] and ls[4==ls[5]==ls[6]==ls[7] and ls[8]==ls[9]==ls[10]==ls[11]: print('yes') else: print('no')
ls = list(map(int, input().split())) ls.sort() if ls[0]==ls[1]==ls[2]==ls[3] and ls[4]==ls[5]==ls[6]==ls[7] and ls[8]==ls[9]==ls[10]==ls[11]: print('yes') else: print('no')
s945495754
s739885849
p00341
python
Runtime Error
import math x, y = map(int,input().split()) print(math.gcd(x, y))
def gcd(a, b): while b: a, b = b, a%b return a x, y = map(int,input().split()) print(gcd(x, y))
s266132597
s073745819
p02256
python
Runtime Error
input() S = input().split() input() T = input().split() count = 0 for t in T: if t in S: count += 1 print(count)
input() S = set(input().split()) input() T = set(input().split()) count = 0 for t in T: if t in S: count += 1 print(count)
s351662903
s690964928
p02268
python
Time Limit Exceeded
ls = [] for i in range(int(input())): command, text = input().split() if command == "insert": ls.append(text) else: if ls.count(text) >= 1: print("yes") else: print("no")
dic = {} line = [] for i in range(int(input())): line.append(input().split()) for i in line: if i[0][0] == "i": dic[i[1]] = None else: print("yes" if i[1] in dic else "no")
s066795277
s479148148
p02269
python
Time Limit Exceeded
ls = [] for i in range(int(input())): command, text = input().split() if command == "insert": ls.append(text) else: print("yes" if text in ls else "no")
dic = {} line = [] for i in range(int(input())): line.append(input().split()) for i in line: if i[0][0] == "i": dic[i[1]] = None else: print("yes" if i[1] in dic else "no")
s566805474
s479148148
p02269
python
Time Limit Exceeded
import sys ls = [] line = map(lambda x:x.split(), sys.stdin.readlines()) for i in line: if i[0] == "insert": ls.append(i[1]) else: print("yes" if i[1] in ls else "no")
dic = {} line = [] for i in range(int(input())): line.append(input().split()) for i in line: if i[0][0] == "i": dic[i[1]] = None else: print("yes" if i[1] in dic else "no")
s310686763
s479148148
p02269
python
Runtime Error
import sys input() ls = [] line = map(lambda x:x.split(), sys.stdin.readlines()) for i in line: if i[0] == "insert": ls.append(i[1]) else: print("yes" if i[1] in ls else "no")
dic = {} line = [] for i in range(int(input())): line.append(input().split()) for i in line: if i[0][0] == "i": dic[i[1]] = None else: print("yes" if i[1] in dic else "no")
s309413886
s479148148
p02269
python
Time Limit Exceeded
import math x1, y1, x2, y2 = map(int, input().split()) x = x2 - x1 y = y2 - y1 result = x**2 + y**2 print(math.sqrt(result))
import math x1, y1, x2, y2 = map(float, input().split()) x = x2 - x1 y = y2 - y1 result = x**2 + y**2 print(math.sqrt(result))
s303091371
s359220013
p02379
python
Runtime Error
import statistics while True: x = input() if x == 0: break else: ls = list(map(int, input().split())) print(statistics.pstdev(ls))
import statistics while True: x = int(input()) if x == 0: break else: ls = list(map(int, input().split())) print("{0:.8f}".format(statistics.pstdev(ls)))
s609309628
s753410876
p02381
python
Runtime Error
import statistics while True: x = input() if x == 0: break else: ls = list(map(int, input().split())) print("{0:.8f}".format(statistics.pstdev(ls)))
import statistics while True: x = int(input()) if x == 0: break else: ls = list(map(int, input().split())) print("{0:.8f}".format(statistics.pstdev(ls)))
s049054554
s753410876
p02381
python
Runtime Error
print(int(input(x???????????\?????????????????????))**3)
print(int(input())**3)
s116987010
s151129609
p02388
python
Runtime Error
import re t = re.search(r"(\d{1,3})\s(\d{1,3})", input("")) a = t.group(1) b = t.group(2) x = a * b y = a*2 + b*2 print(x,y)
a, b =map(int, input().split()) print(a*b,2*(a+b))
s530851568
s386239055
p02389
python
Runtime Error
x = input("") x2 = x.split() result = x2[0] * x2[1] result2= x2[0]*2 + x2[1]*2 print(result,result2)
a, b =map(int, input().split()) print(a*b,2*(a+b))
s660639431
s386239055
p02389
python
Runtime Error
time = input("") h = time // 3600 h2 = time % 3600 m = h2 // 60 m2 = h2 % 60 s = m2 print(h+:+m+:+s)
S = int(input()) h = S//3600 m = (S%3600) // 60 s = (S%3600)%60 h = str(h) m= str(m) s = str(s) print(h+":"+m+":"+s)
s115197865
s467652768
p02390
python
Runtime Error
import re given = input("") result = re.search(r"([0-9]+)\s([0-9]+)", given) a = int(result.group(1)) b = int(result.group(2)) if a == b: print(a, ==, b) elif a < b: print(a, <, b) else: print(a, >, b)
a, b = map(int, input().split()) if a<b: print("a < b") elif a>b: print("a > b") else: print("a == b")
s630231389
s438727626
p02391
python
Runtime Error
count = 0 while True: x=input("") count+=1 print("Case ",str(count) + ":", x)
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s410346740
s986234063
p02396
python
Runtime Error
count = 0 while True: x=input("") count+=1 print("Case",str(count) + ":", x)
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s948690629
s986234063
p02396
python
Runtime Error
count = 0 x=None while (x == 0) == False: x=input("") int(count) count+=1 print("Case",str(count)+":", x)
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s615836648
s986234063
p02396
python
Runtime Error
x = input("") count=1 while x != 0: print("Case",str(count)+":",x) count = int(count) + 1 x = input("")
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s132038685
s986234063
p02396
python
Runtime Error
x = input("") count = 1 while True: print("Case",str(count)+":",input("")) count = int(count) + 1 if x == 0: break
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s259107276
s986234063
p02396
python
Runtime Error
count = 1 while True: print("Case",str(count)+":",input("")) count = int(count) + 1 if x == 0: break
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s903459522
s986234063
p02396
python
Runtime Error
count = 1 while True: x = input("") print("Case",str(count)+":",x) count = int(count) + 1 if x == 0: break
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s301917411
s986234063
p02396
python
Runtime Error
count = 1 t=[] while True: x = input("") if x == "0": break else: t.append("Case",str(count)+":",x) count = int(count) + 1 for i in t: print(t[i])
t=[] while True: x = str(input("")) if x == "0": break else: t.append(x) for i,v in enumerate(t): print("Case",str(i+1)+":",v)
s557020030
s986234063
p02396
python
Runtime Error
list1=[] while True: x = str(input("")) if x == "0": break else: list1.append(x) for i,v in enumerate(list1): x,y = map(int,v.split()) if x < y: print(str(x) + " " + str(y)) else: print(str(y) + " " + str(x))
list1=[] while True: x = input("") if x == "0 0": break else: list1.append(x) for i,v in enumerate(list1): x,y = map(int,v.split()) if x <= y: print(str(x) + " " + str(y)) else: print(str(y) + " " + str(x))
s401396381
s610196769
p02397
python
Runtime Error
a, b, c = map(int, input().split()) for i in range(a, b): if i % c == 0: result += str(c)+" " print(result)
a, b, c = map(int, input().split()) result = 0 for i in range(a, b+1): if c % i == 0: result += 1 print(result)
s969091884
s757834814
p02398
python
Runtime Error
a, b = map(int, input().split()) d = a // b r = a % b f = a / b print(d,r,{0:.5f}.format)
a, b = map(int, input().split()) d = a // b r = a % b f = a / b print(d,r,"{0:.5f}".format(f))
s795583432
s278162651
p02399
python
Runtime Error
a, b = map(int, input().split()) d = a // b r = a % b f = a / b print(d,r,"{0:.5f}".format)(f)
a, b = map(int, input().split()) d = a // b r = a % b f = a / b print(d,r,"{0:.5f}".format(f))
s288010113
s278162651
p02399
python
Runtime Error