message stringlengths 2 20.2k | message_type stringclasses 2
values | message_id int64 0 1 | conversation_id int64 757 108k | cluster float64 4 4 | __index_level_0__ int64 1.51k 217k |
|---|---|---|---|---|---|
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Your task is to write a program which reads a date (from 2004/1/1 to 2004/12/31) and prints the day of the date. Jan. 1, 2004, is Thursday. Note that 2004 is a leap year and we have Feb. 29.
... | instruction | 0 | 88,278 | 4 | 176,556 |
No | output | 1 | 88,278 | 4 | 176,557 |
Provide a correct Python 3 solution for this coding contest problem.
Problem
Neat lives on the world line for a total of 360 days until the 30th of every month for 1 year and 12 months. In that world, N consecutive holidays with the same schedule were applied to people all over the world every year. Consecutive holid... | instruction | 0 | 88,309 | 4 | 176,618 |
"Correct Solution:
```
D = 360
x = [0 for i in range(D)]
n = int(input())
for i in range(n):
m,d,v,s = map(int,input().split())
m -= 1
d -= 1
start = 30*m+d
end = (start+v-1)%D
h = [False for _ in range(D)]
for j in range(v):
y = (start+j)%D
h[y] = True
for j in range(... | output | 1 | 88,309 | 4 | 176,619 |
Provide a correct Python 3 solution for this coding contest problem.
Problem
Neat lives on the world line for a total of 360 days until the 30th of every month for 1 year and 12 months. In that world, N consecutive holidays with the same schedule were applied to people all over the world every year. Consecutive holid... | instruction | 0 | 88,310 | 4 | 176,620 |
"Correct Solution:
```
N = input()
N = int(N)+1
X = [0]
C = [0]*360
for i in range(1,N):
x = input()
X.append(x.split())
i_start = (int(X[i][0])-1)*30+int(X[i][1])-1
i_end = i_start+int(X[i][2])-1
for j in range(i_start,i_end+1):
C[j%360] = max(C[j%360],int(X[i][3]))
for k in range(1... | output | 1 | 88,310 | 4 | 176,621 |
Provide a correct Python 3 solution for this coding contest problem.
Problem
Neat lives on the world line for a total of 360 days until the 30th of every month for 1 year and 12 months. In that world, N consecutive holidays with the same schedule were applied to people all over the world every year. Consecutive holid... | instruction | 0 | 88,311 | 4 | 176,622 |
"Correct Solution:
```
n = int(input())
eff = [0]*360
days = [list(map(int, input().split())) for i in range(n)]
for m, d, v, s in days:
# [a, b)
a = (m-1)*30 + d - 1
b = a + v
for i in range(a, b):
eff[i%360] = max(eff[i%360], s)
for i in range(b, a+360):
eff[i%360] = max(eff[i%360... | output | 1 | 88,311 | 4 | 176,623 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,340 | 4 | 176,680 |
Tags: brute force, implementation, math
Correct Solution:
```
from collections import defaultdict
def read_int():
return list(map(int, input().split()))
n, k = read_int()
arr = read_int()
sumv = defaultdict(int)
for i in range(n):
sumv[i] = sumv[i-1] + arr[i]
ans = []
for i in range(0, n - k + 1):
f... | output | 1 | 88,340 | 4 | 176,681 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,341 | 4 | 176,682 |
Tags: brute force, implementation, math
Correct Solution:
```
def main():
n,k=map(int,input().split( ))
a=list(map(int,input().split( )))
ans=-1*10**9+7
for i in range(n):
s=0
for j in range(i,n):
s+=a[j]
if j-i+1>=k:
ans=max(ans,s/(j-i+1))
pr... | output | 1 | 88,341 | 4 | 176,683 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,342 | 4 | 176,684 |
Tags: brute force, implementation, math
Correct Solution:
```
import sys,math,bisect
inf = float('inf')
mod = (10**9)+7
"=========================="
def lcm(a,b):
return int((a/math.gcd(a,b))*b)
def gcd(a,b):
return int(math.gcd(a,b))
def tobinary(n):
return bin(n)[2:]
def binarySearch(a,x):
i = bisect... | output | 1 | 88,342 | 4 | 176,685 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,343 | 4 | 176,686 |
Tags: brute force, implementation, math
Correct Solution:
```
n, k = map(int, input().split())
a = list(map(int, input().split())) + [0]
q = [0] * (n + 1)
for i in range(1, n + 1):
q[i] = q[i - 1] + a[i - 1]
s = 0
for i in range(n):
j = 0
while i + k + j <= n:
rec = (q[i + k + j] - q[i]) / (k + j)
... | output | 1 | 88,343 | 4 | 176,687 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,344 | 4 | 176,688 |
Tags: brute force, implementation, math
Correct Solution:
```
if __name__ == "__main__":
firstRange = 0
intensitySum = 0
rangeSum = 0
intensity = 0
n, k = tuple(map(int,input().split()))
a = tuple(map(int,input().split()))
for i in range(k-1):
firstRange += a[i]
for _len in ran... | output | 1 | 88,344 | 4 | 176,689 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,345 | 4 | 176,690 |
Tags: brute force, implementation, math
Correct Solution:
```
from itertools import accumulate
n, k = map(int, input().split())
a = list(map(int, input().split()))
acc = [0] + list(accumulate(a))
ans = 0
for i in range(n - k + 1):
for j in range(i + k, n + 1):
s = acc[j] - acc[i]
t = s / (j - i)
... | output | 1 | 88,345 | 4 | 176,691 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,346 | 4 | 176,692 |
Tags: brute force, implementation, math
Correct Solution:
```
import sys
input = sys.stdin.readline
n, k = map(int, input().split())
a = [0] + list(map(int, input().split()))
for i in range(1, n + 1):
a[i] += a[i - 1]
ans = 0
for i in range(k, n + 1):
for j in range(n - i + 1):
ans = max(ans, (a[i + j]... | output | 1 | 88,346 | 4 | 176,693 |
Provide tags and a correct Python 3 solution for this coding contest problem.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. But any scientific claim sounds a lot more reas... | instruction | 0 | 88,347 | 4 | 176,694 |
Tags: brute force, implementation, math
Correct Solution:
```
n,k=map(int,input().split())
arr=list(map(int,input().split()))
find=[0]*n
for i in range(n):
find[i]=[0]*n
presum=[0]*n
presum[0]=arr[0]
for i in range(1,n):
presum[i]=presum[i-1]+arr[i]
for i in range(n-k+1):
for j in range(i+k-1,n):
if i==0:
find[... | output | 1 | 88,347 | 4 | 176,695 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,348 | 4 | 176,696 |
Yes | output | 1 | 88,348 | 4 | 176,697 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,349 | 4 | 176,698 |
Yes | output | 1 | 88,349 | 4 | 176,699 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,350 | 4 | 176,700 |
Yes | output | 1 | 88,350 | 4 | 176,701 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,351 | 4 | 176,702 |
Yes | output | 1 | 88,351 | 4 | 176,703 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,352 | 4 | 176,704 |
No | output | 1 | 88,352 | 4 | 176,705 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,353 | 4 | 176,706 |
No | output | 1 | 88,353 | 4 | 176,707 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,354 | 4 | 176,708 |
No | output | 1 | 88,354 | 4 | 176,709 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
The heat during the last few days has been really intense. Scientists from all over the Berland study how the temperatures and weather change, and they claim that this summer is abnormally hot. ... | instruction | 0 | 88,355 | 4 | 176,710 |
No | output | 1 | 88,355 | 4 | 176,711 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,423 | 4 | 176,846 |
Yes | output | 1 | 88,423 | 4 | 176,847 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,424 | 4 | 176,848 |
Yes | output | 1 | 88,424 | 4 | 176,849 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,425 | 4 | 176,850 |
Yes | output | 1 | 88,425 | 4 | 176,851 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,426 | 4 | 176,852 |
Yes | output | 1 | 88,426 | 4 | 176,853 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,427 | 4 | 176,854 |
No | output | 1 | 88,427 | 4 | 176,855 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,428 | 4 | 176,856 |
No | output | 1 | 88,428 | 4 | 176,857 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,429 | 4 | 176,858 |
No | output | 1 | 88,429 | 4 | 176,859 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Ivan recently bought a detective book. The book is so interesting that each page of this book introduces some sort of a mystery, which will be explained later. The i-th page contains some myster... | instruction | 0 | 88,430 | 4 | 176,860 |
No | output | 1 | 88,430 | 4 | 176,861 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Amr is a young coder who likes music a lot. He always wanted to learn how to play music but he was busy coding so he got an idea.
Amr has n instruments, it takes ai days to learn i-th instrumen... | instruction | 0 | 88,832 | 4 | 177,664 |
No | output | 1 | 88,832 | 4 | 177,665 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,905 | 4 | 177,810 |
Tags: geometry, math
Correct Solution:
```
h,m = list(map(int,input().split(':')))
print((h*30+m/2)%360,m*6)
``` | output | 1 | 88,905 | 4 | 177,811 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,906 | 4 | 177,812 |
Tags: geometry, math
Correct Solution:
```
s=input()
h=int(s[:2])
m=int(s[3:])
print(h%12*30+m/2,m*6)
# Made By Mostafa_Khaled
``` | output | 1 | 88,906 | 4 | 177,813 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,907 | 4 | 177,814 |
Tags: geometry, math
Correct Solution:
```
H, M = [int(x) for x in input().split(':')]
H = H % 12
hAngle = 360 / 12
hmAngle = hAngle / 60
mAngle = 360 / 60
print(H * hAngle + M * hmAngle, end=' ')
print(M * mAngle)
``` | output | 1 | 88,907 | 4 | 177,815 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,908 | 4 | 177,816 |
Tags: geometry, math
Correct Solution:
```
def readln(): return tuple(map(int, input().split()))
hh, mm = tuple(map(int, input().split(':')))
print(30 * (hh % 12) + 0.5 * mm, 6 * mm)
``` | output | 1 | 88,908 | 4 | 177,817 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,909 | 4 | 177,818 |
Tags: geometry, math
Correct Solution:
```
import sys
import string
from collections import Counter, defaultdict
from math import fsum, sqrt, gcd, ceil, factorial
from operator import *
from itertools import accumulate
inf = float("inf")
# input = sys.stdin.readline
flush = lambda: sys.stdout.flush
comb = lambda x, y... | output | 1 | 88,909 | 4 | 177,819 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,910 | 4 | 177,820 |
Tags: geometry, math
Correct Solution:
```
hh, mm = map(int, input().split(":"))
print((hh%12)*30 + mm/2, mm*6)
``` | output | 1 | 88,910 | 4 | 177,821 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,911 | 4 | 177,822 |
Tags: geometry, math
Correct Solution:
```
#
# solving:
# from: https://vjudge.net/contest/417235#problem/D
def main():
inlist = input().split(":")
hh, mm = int(inlist[0]), int(inlist[1])
deg_per_h = 360/12
deg_per_m = 360/60
print("{} {}".format(((hh+mm/60) * deg_per_h) % 360, (mm * deg_per_m... | output | 1 | 88,911 | 4 | 177,823 |
Provide tags and a correct Python 3 solution for this coding contest problem.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the Beast's order and visited the West Wing. After... | instruction | 0 | 88,912 | 4 | 177,824 |
Tags: geometry, math
Correct Solution:
```
#
# solving:
# from: https://vjudge.net/contest/417235#problem/D
# Fits the specification exactly uwu
def main():
inlist = input().split(":")
hh, mm = int(inlist[0]), int(inlist[1])
deg_per_h = 360/12
deg_per_m = 360/60
hours = ((hh+mm/60) * deg_per_... | output | 1 | 88,912 | 4 | 177,825 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,913 | 4 | 177,826 |
Yes | output | 1 | 88,913 | 4 | 177,827 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,914 | 4 | 177,828 |
Yes | output | 1 | 88,914 | 4 | 177,829 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,915 | 4 | 177,830 |
Yes | output | 1 | 88,915 | 4 | 177,831 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,916 | 4 | 177,832 |
Yes | output | 1 | 88,916 | 4 | 177,833 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,917 | 4 | 177,834 |
No | output | 1 | 88,917 | 4 | 177,835 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,918 | 4 | 177,836 |
No | output | 1 | 88,918 | 4 | 177,837 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,919 | 4 | 177,838 |
No | output | 1 | 88,919 | 4 | 177,839 |
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response.
Do you remember a kind cartoon "Beauty and the Beast"? No, no, there was no firing from machine guns or radiation mutants time-travels!
There was a beauty named Belle. Once she had violated the... | instruction | 0 | 88,920 | 4 | 177,840 |
No | output | 1 | 88,920 | 4 | 177,841 |
Provide a correct Python 3 solution for this coding contest problem.
Niwango created a playlist of N songs. The title and the duration of the i-th song are s_i and t_i seconds, respectively. It is guaranteed that s_1,\ldots,s_N are all distinct.
Niwango was doing some work while playing this playlist. (That is, all t... | instruction | 0 | 89,023 | 4 | 178,046 |
"Correct Solution:
```
n = int(input())
musics = [input().split() for _ in range(n)]
x = input()
not_yet = True
ans = 0
for m, s in musics:
if not not_yet:
ans += int(s)
if x == m:
not_yet = False
print(ans)
``` | output | 1 | 89,023 | 4 | 178,047 |
Provide a correct Python 3 solution for this coding contest problem.
Niwango created a playlist of N songs. The title and the duration of the i-th song are s_i and t_i seconds, respectively. It is guaranteed that s_1,\ldots,s_N are all distinct.
Niwango was doing some work while playing this playlist. (That is, all t... | instruction | 0 | 89,024 | 4 | 178,048 |
"Correct Solution:
```
n=int(input())
S=[]
T=[]
for i in range(n):
s,t=input().split()
S.append(s)
T.append(int(t))
print(sum(T[S.index(input())+1:]))
``` | output | 1 | 89,024 | 4 | 178,049 |
Provide a correct Python 3 solution for this coding contest problem.
Niwango created a playlist of N songs. The title and the duration of the i-th song are s_i and t_i seconds, respectively. It is guaranteed that s_1,\ldots,s_N are all distinct.
Niwango was doing some work while playing this playlist. (That is, all t... | instruction | 0 | 89,025 | 4 | 178,050 |
"Correct Solution:
```
N=int(input())
s,t=[0]*N,[0]*N
for i in range(N):
s[i],t[i]=input().split()
X=input()
print(sum(list(map(int,t[s.index(X)+1:]))))
``` | output | 1 | 89,025 | 4 | 178,051 |
Provide a correct Python 3 solution for this coding contest problem.
Niwango created a playlist of N songs. The title and the duration of the i-th song are s_i and t_i seconds, respectively. It is guaranteed that s_1,\ldots,s_N are all distinct.
Niwango was doing some work while playing this playlist. (That is, all t... | instruction | 0 | 89,026 | 4 | 178,052 |
"Correct Solution:
```
n = int(input())
title = []
length = []
for i in range(n):
a, b = input().split()
title.append(a)
length.append(int(b))
i = title.index(input())
print(sum((length[i+1:])))
``` | output | 1 | 89,026 | 4 | 178,053 |
Provide a correct Python 3 solution for this coding contest problem.
Niwango created a playlist of N songs. The title and the duration of the i-th song are s_i and t_i seconds, respectively. It is guaranteed that s_1,\ldots,s_N are all distinct.
Niwango was doing some work while playing this playlist. (That is, all t... | instruction | 0 | 89,027 | 4 | 178,054 |
"Correct Solution:
```
n=int(input())
s=[]
t=[]
for i in range(n):
ss,tt=input().split()
s.append(ss)
t.append(int(tt))
print(sum(t[s.index(input())+1:]))
``` | output | 1 | 89,027 | 4 | 178,055 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.