problem_id stringlengths 3 7 | contestId stringclasses 660
values | problem_index stringclasses 27
values | programmingLanguage stringclasses 3
values | testset stringclasses 5
values | incorrect_passedTestCount float64 0 146 | incorrect_timeConsumedMillis float64 15 4.26k | incorrect_memoryConsumedBytes float64 0 271M | incorrect_submission_id stringlengths 7 9 | incorrect_source stringlengths 10 27.7k | correct_passedTestCount float64 2 360 | correct_timeConsumedMillis int64 30 8.06k | correct_memoryConsumedBytes int64 0 475M | correct_submission_id stringlengths 7 9 | correct_source stringlengths 28 21.2k | contest_name stringclasses 664
values | contest_type stringclasses 3
values | contest_start_year int64 2.01k 2.02k | time_limit float64 0.5 15 | memory_limit float64 64 1.02k | title stringlengths 2 54 | description stringlengths 35 3.16k | input_format stringlengths 67 1.76k | output_format stringlengths 18 1.06k ⌀ | interaction_format null | note stringclasses 840
values | examples stringlengths 34 1.16k | rating int64 800 3.4k ⌀ | tags stringclasses 533
values | testset_size int64 2 360 | official_tests stringlengths 44 19.7M | official_tests_complete bool 1
class | input_mode stringclasses 1
value | generated_checker stringclasses 231
values | executable bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
113/A | 113 | A | Python 3 | TESTS | 136 | 92 | 102,400 | 212181856 | a=input().split()
i=0
n=len(a)
while i<n and (len(a[i])>=4 and a[i][len(a[i])-4:]=="lios"):
i+=1
i1=i
while i<n and (len(a[i])>=3 and a[i][len(a[i])-3:]=="etr"):
i+=1
if i-i1!=1 and i!=0 and n>1:
print("NO")
exit()
while i<n and (len(a[i])>=6 and a[i][len(a[i])-6:]=="initis"):
i+=1
#print(i)
if i==0... | 360 | 78 | 307,200 | 4075975 | s=input().split()
if(len(s)==1):
if(s[0].endswith("lios") or s[0].endswith("etr") or s[0].endswith("liala") or s[0].endswith("etra") or s[0].endswith("inites") or s[0].endswith("initis")):
print("YES")
else:
print("NO")
elif(s[0].endswith("lios") or s[0].endswith("etr")):
n=len(s)
i=... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | Python 3 | TESTS | 65 | 92 | 102,400 | 151378536 | def isPetyaLanguage():
read = input().split()
if len(read) == 1:
if read[0].endswith('lios') or read[0].endswith('lialia') or read[0].endswith('etr') or read[0].endswith('etra') or read[0].endswith('initis') or read[0].endswith('inites'):
print('YES')
return
else:
... | 360 | 92 | 102,400 | 151322401 | def isPetyaLanguage():
words = input().split()
if len(words) == 1:
if words[0].endswith("etr") or words[0].endswith("etra") or words[0].endswith("lios") or words[0].endswith("liala") or words[0].endswith("initis") or words[0].endswith("inites"):
print("YES")
return
else:
... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | PyPy 3-64 | TESTS | 146 | 156 | 716,800 | 171980063 | from collections import defaultdict as dc
words=input().split()
ends=['lios','liala','etr','etra','initis','inites']
adjm,adjf,verbm,verbf,nounm,nounf,=set(),set(),set(),set(),set(),set()
for s in words:
n=len(s)
for i in ends:
idx=len(s)-len(i)
if idx<0:continue
j,flag=0,0
while... | 360 | 92 | 102,400 | 214687216 | from sys import stdin, stdout
x = stdin.readline().replace("\n","")
lst = x.split(' ')
genderLst = []
typeLst = []
valid = 1
for x in lst:
if x.endswith("lios") or x.endswith("etr") or x.endswith("initis"):
genderLst.append(1)
elif x.endswith("liala") or x.endswith("etra") or x.endswith("inites"... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | PyPy 3-64 | TESTS | 101 | 124 | 204,800 | 212179196 | def get_type(slovo):
slovo = slovo[::-1]
slovo += '#######'
if slovo[:4] == 'soil':
return [0, 0]
if slovo[:5] == 'alail':
return [0, 1]
if slovo[:3] == 'rte':
return [1, 0]
if slovo[:4] == 'arte':
return [1, 1]
if slovo[:6] == 'sitini':
return [2, 0]
... | 360 | 92 | 102,400 | 227284427 | # LUOGU_RID: 128399015
a = input().split()
c = 5 #设置一个变量,记录当前的状态
for b in a:
if c == 5:
if len(a) == 1:
if b[-4:] == 'lios' or b[-5:] == 'liala' or b[-3:] == 'etr' or b[-4:] == 'etra' or b[-6:] == 'initis' or b[-6:] == 'inites': #输入只有一个任意合法单词时也特判为合法
c = 0
elif b[-4:] == ... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | PyPy 3-64 | TESTS | 7 | 124 | 614,400 | 171980252 | from collections import defaultdict as dc
words=input().split()
ends=['lios','liala','etr','etra','initis','inites']
adjm,adjf,verbm,verbf,nounm,nounf,=set(),set(),set(),set(),set(),set()
frq=dc(lambda:0)
for s in words:
n=len(s)
for i in ends:
idx=len(s)-len(i)
if idx<0:continue
j,flag=... | 360 | 122 | 4,710,400 | 157359820 | n = input().split()
w = 0
x=y=z=0
r=s=t=0
while w<len(n):
if n[w][-4:]=="lios" or n[w][-5:]=="liala":
if n[w][-4:]=="lios":
x+=1
w+=1
else:
r+=1
w+=1
else:
break
while w<len(n):
if n[w][-3:]=="etr" or n[w][-4:]=="etra":
if n[w][... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | PyPy 3 | TESTS | 7 | 184 | 0 | 11937161 | def pos(w):
if len(w) < 3:
return False
if w == 'etr' or w[-3:] == 'etr':
return 'MN'
if len(w) == 3:
return False
if w == 'lios' or w[-4:] == 'lios':
return 'MA'
if w == 'etra' or w[-4:] == 'etra':
return 'FN'
if len(w) == 4:
return False
if w... | 360 | 124 | 102,400 | 151380136 | '''
def isPetyaLanguage():
read = input().split(' ')
if len(read) == 1:
if read[0].endswith('lios') or read[0].endswith('lialia') or read[0].endswith('etr') or read[0].endswith('etra') or read[0].endswith('initis') or read[0].endswith('inites'):
print('YES')
return
else:
... | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | Petya got interested in grammar on his third year in school. He invented his own language called Petya's. Petya wanted to create a maximally simple language that would be enough to chat with friends, that's why all the language's grammar can be described with the following set of rules:
- There are three parts of spee... | The first line contains one or more words consisting of lowercase Latin letters. The overall number of characters (including letters and spaces) does not exceed 105.
It is guaranteed that any two consecutive words are separated by exactly one space and the input data do not contain any other spaces. It is possible tha... | If some word of the given text does not belong to the Petya's language or if the text contains more that one sentence, print "NO" (without the quotes). Otherwise, print "YES" (without the quotes). | null | null | [{"input": "petr", "output": "YES"}, {"input": "etis atis animatis etis atis amatis", "output": "NO"}, {"input": "nataliala kataliala vetra feinites", "output": "YES"}] | 1,600 | ["implementation", "strings"] | 360 | [{"input": "petr\r\n", "output": "YES\r\n"}, {"input": "etis atis animatis etis atis amatis\r\n", "output": "NO\r\n"}, {"input": "nataliala kataliala vetra feinites\r\n", "output": "YES\r\n"}, {"input": "qweasbvflios\r\n", "output": "YES\r\n"}, {"input": "lios lios petr initis qwe\r\n", "output": "NO\r\n"}, {"input": "... | false | stdio | null | true |
113/A | 113 | A | Python 3 | TESTS | 7 | 186 | 307,200 | 91305797 | "s=list(map(str,input().split(' ')))\ng=[['lios','liala'],['etr','etra'],['initis','inites']]\nif le(...TRUNCATED) | 360 | 124 | 204,800 | 208405599 | "class Context:\n def __init__(self, words):\n self.words = words\n self.index = 0\(...TRUNCATED) | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | "Petya got interested in grammar on his third year in school. He invented his own language called Pe(...TRUNCATED) | "The first line contains one or more words consisting of lowercase Latin letters. The overall number(...TRUNCATED) | "If some word of the given text does not belong to the Petya's language or if the text contains more(...TRUNCATED) | null | null | "[{\"input\": \"petr\", \"output\": \"YES\"}, {\"input\": \"etis atis animatis etis atis amatis\", \(...TRUNCATED) | 1,600 | ["implementation", "strings"] | 360 | "[{\"input\": \"petr\\r\\n\", \"output\": \"YES\\r\\n\"}, {\"input\": \"etis atis animatis etis atis(...TRUNCATED) | false | stdio | null | true |
113/A | 113 | A | Python 3 | TESTS | 66 | 156 | 204,800 | 22654372 | "ms = input().split()\nal = [['lios','etr','initis'],['liala','etra','inites']]\n\ns = ms[0]\ni=0;\n(...TRUNCATED) | 360 | 124 | 614,400 | 162396833 | "import re;t=input();p=[r'([^ ]*lios )*([^ ]*etr)( [^ ]*initis)*',r'([^ ]*liala )*([^ ]*etra)( [^ ]*(...TRUNCATED) | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | "Petya got interested in grammar on his third year in school. He invented his own language called Pe(...TRUNCATED) | "The first line contains one or more words consisting of lowercase Latin letters. The overall number(...TRUNCATED) | "If some word of the given text does not belong to the Petya's language or if the text contains more(...TRUNCATED) | null | null | "[{\"input\": \"petr\", \"output\": \"YES\"}, {\"input\": \"etis atis animatis etis atis amatis\", \(...TRUNCATED) | 1,600 | ["implementation", "strings"] | 360 | "[{\"input\": \"petr\\r\\n\", \"output\": \"YES\\r\\n\"}, {\"input\": \"etis atis animatis etis atis(...TRUNCATED) | false | stdio | null | true |
113/A | 113 | A | Python 3 | TESTS | 66 | 216 | 8,396,800 | 127696390 | "import sys\nfrom functools import lru_cache, cmp_to_key\nfrom heapq import merge, heapify, heappop,(...TRUNCATED) | 360 | 154 | 204,800 | 15182995 | "s, n, m, f = input().split(), False, False, False\ndef cc(w, me, fe):\n global m, f\n if w.en(...TRUNCATED) | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | "Petya got interested in grammar on his third year in school. He invented his own language called Pe(...TRUNCATED) | "The first line contains one or more words consisting of lowercase Latin letters. The overall number(...TRUNCATED) | "If some word of the given text does not belong to the Petya's language or if the text contains more(...TRUNCATED) | null | null | "[{\"input\": \"petr\", \"output\": \"YES\"}, {\"input\": \"etis atis animatis etis atis amatis\", \(...TRUNCATED) | 1,600 | ["implementation", "strings"] | 360 | "[{\"input\": \"petr\\r\\n\", \"output\": \"YES\\r\\n\"}, {\"input\": \"etis atis animatis etis atis(...TRUNCATED) | false | stdio | null | true |
113/A | 113 | A | Python 3 | TESTS | 66 | 218 | 614,400 | 99499790 | "lista = input().split()\n\npassadj = False\npasssub = False\ngender = -1\ncan = True\n\n# verifican(...TRUNCATED) | 360 | 216 | 716,800 | 15383496 | "#!/usr/bin/python3\nimport re\nal = re.compile(r'^1*23*$')\ndef getType(word):\n\tif word.endswith((...TRUNCATED) | Codeforces Beta Round 86 (Div. 1 Only) | CF | 2,011 | 5 | 256 | Grammar Lessons | "Petya got interested in grammar on his third year in school. He invented his own language called Pe(...TRUNCATED) | "The first line contains one or more words consisting of lowercase Latin letters. The overall number(...TRUNCATED) | "If some word of the given text does not belong to the Petya's language or if the text contains more(...TRUNCATED) | null | null | "[{\"input\": \"petr\", \"output\": \"YES\"}, {\"input\": \"etis atis animatis etis atis amatis\", \(...TRUNCATED) | 1,600 | ["implementation", "strings"] | 360 | "[{\"input\": \"petr\\r\\n\", \"output\": \"YES\\r\\n\"}, {\"input\": \"etis atis animatis etis atis(...TRUNCATED) | false | stdio | null | true |
End of preview. Expand in Data Studio
notes: some examples appear to be contaminated (examples are contained in test cases)
Filtering
- selected_incorrect: filter to Python3 family + verdict == WRONG_ANSWER
- selected_accepted: keep first Python3 family correct reference per problem_id in the above set, otherwise drop row
- verifiable: keep rows whose id is in the above set
- apply final filters: no interaction, input mode == stdio, executable.
[Stage 1] selected_incorrect processed=18097 kept_after_filters=8363 unique_problem_ids=1778
[Stage 2] default processed_total=12591518 kept_lang_ok=745330 considered_in_target=119338 replacements=13707
[Stage 2] coverage: full=1131 partial=249 zero=398 total_kept_candidates=6802
[Stage 3] verifiable processed=8760 matched_problem_ids=1693
[Stage 4] incorrect_tmp_rows=8363 joined_ok=7218 dropped_no_correct=915 dropped_no_verifiable=230
[Stage 4] before_final_filters=7218 dropped_interaction_present=0 dropped_rating=0 dropped_input_mode=76 dropped_executable=0 final_written=7142
[Stage 4] pairing duplicates_used_rows=646 problems_with_insufficient_corrects=249
- Downloads last month
- 6