Dataset Viewer
Auto-converted to Parquet
example_id
int64
0
63
prompt
listlengths
1
1
completion
listlengths
1
1
task
stringclasses
1 value
reward
float64
-1
1
generation_ms
float64
23.7k
87.8k
scoring_ms
float64
0.13
1.19k
total_ms
float64
23.7k
87.8k
info
dict
has_error
float64
0
1
passed
float64
0
1
num_test_cases
float64
5
15
pass_rate
float64
0
1
0
[ { "content": "Solve the programming task below in a Python markdown code block.\n\nThere are three cards with letters $\\texttt{a}$, $\\texttt{b}$, $\\texttt{c}$ placed in a row in some order. You can do the following operation at most once: \n\n \n- Pick two cards, and swap them. Is it possible that the row becomes $\\texttt{abc}$ after the operation? Output \"YES\" if it is possible, and \"NO\" otherwise.\n\nInput\n\nThe first line contains a single integer $t$ ($1 \\leq t \\leq 6$) — the number of test cases.\n\nThe only line of each test case contains a single string consisting of each of the three characters $\\texttt{a}$, $\\texttt{b}$, and $\\texttt{c}$ exactly once, representing the cards.\n\nOutput\n\nFor each test case, output \"YES\" if you can make the row $\\texttt{abc}$ with at most one operation, or \"NO\" otherwise.\n\nYou can output the answer in any case (for example, the strings \"yEs\", \"yes\", \"Yes\" and \"YES\" will be recognized as a positive answer).Sample Input 1:\n6\n\nabc\n\nacb\n\nbac\n\nbca\n\ncab\n\ncba\n\n\n\nSample Output 1:\n\nYES\nYES\nYES\nNO\nNO\nYES\n\n\nNote\n\nIn the first test case, we don't need to do any operations, since the row is already $\\texttt{abc}$.\n\nIn the second test case, we can swap $\\texttt{c}$ and $\\texttt{b}$: $\\texttt{acb} \\to \\texttt{abc}$.\n\nIn the third test case, we can swap $\\texttt{b}$ and $\\texttt{a}$: $\\texttt{bac} \\to \\texttt{abc}$.\n\nIn the fourth test case, it is impossible to make $\\texttt{abc}$ using at most one operation.\n\nRead the inputs from stdin solve the problem and write the answer to stdout (do not directly test on the sample inputs). Enclose your code within ```python delimiters.", "role": "user" } ]
[ { "content": "```python\nt = int(input())\ntarget = \"abc\"\n\nfor _ in range(t):\n s = input().strip()\n if s == target:\n print(\"YES\")\n continue\n \n # Try all pairs of positions to swap\n possible = False\n s_list = list(s)\n for i in range(3):\n for j in range(i+1, 3):\n s_list[i], s_list[j] = s_list[j], s_list[i]\n if \"\".join(s_list) == target:\n possible = True\n s_list[i], s_list[j] = s_list[j], s_list[i] # swap back\n if possible:\n break\n if possible:\n break\n\n print(\"YES\" if possible else \"NO\")\n```", "role": "assistant" } ]
deepcoder
1
66,350.088358
1,188.142538
67,538.230896
{ "num_test_cases": 5, "source": "lcbv5", "subset": "i3-code", "subset_idx": 0, "verification_info": { "fn_name": null, "test_case_inputs": [ "\"6\\nabc\\nacb\\nbac\\nbca\\ncab\\ncba\\n\"", "\"1\\nabc\\n\"", "\"3\\nabc\\nabc\\nabc\\n\"", "\"5\\ncab\\nacb\\ncba\\nbac\\nbca\\n\"", "\"6\\nabc\\nabc\\nabc\\nabc\\nabc\\nabc\\n\"" ], "test_case_outputs": [ "\"YES\\nYES\\nYES\\nNO\\nNO\\nYES\\n\"", "\"YES\\n\"", "\"YES\\nYES\\nYES\\n\"", "\"NO\\nYES\\nYES\\nYES\\nNO\\n\"", "\"YES\\nYES\\nYES\\nYES\\nYES\\nYES\\n\"" ], "timeout": 10 } }
0
1
5
1
1
[{"content":"Solve the programming task below in a Python markdown code block.\n\nSlavic is preparin(...TRUNCATED)
[{"content":"```python\nt = int(input())\nfor _ in range(t):\n n = int(input())\n a = list(map(...TRUNCATED)
deepcoder
1
39,738.101482
0.211
39,738.312483
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":1,"verification_info":{"fn_nam(...TRUNCATED)
0
1
13
1
2
[{"content":"Solve the programming task below in a Python markdown code block.\n\nYou are given a st(...TRUNCATED)
[{"content":"```python\nimport sys\ninput = sys.stdin.readline\n\nt = int(input())\nfor _ in range(t(...TRUNCATED)
deepcoder
1
41,607.977867
0.195503
41,608.17337
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":2,"verification_info":{"fn_nam(...TRUNCATED)
0
1
13
1
3
[{"content":"Solve the programming task below in a Python markdown code block.\n\nYou are given an a(...TRUNCATED)
[{"content":"```python\nimport sys\ninput = sys.stdin.readline\n\ndef min_ops_to_make_divisible(n, k(...TRUNCATED)
deepcoder
0
70,293.736696
0.136852
70,293.873549
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":3,"verification_info":{"fn_nam(...TRUNCATED)
0
0
13
0.846154
4
[{"content":"Solve the programming task below in a Python markdown code block.\n\nVanya and Vova are(...TRUNCATED)
[{"content":"```python\nt = int(input())\nfor _ in range(t):\n n = int(input())\n \n # If n(...TRUNCATED)
deepcoder
0
38,156.235695
0.197649
38,156.433344
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":4,"verification_info":{"fn_nam(...TRUNCATED)
0
0
13
0.153846
5
[{"content":"Solve the programming task below in a Python markdown code block.\n\nAlex is participat(...TRUNCATED)
[{"content":"```python\nimport sys\ninput = sys.stdin.readline\n\nt = int(input())\nfor _ in range(t(...TRUNCATED)
deepcoder
1
56,989.368439
15.736818
57,005.105257
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":5,"verification_info":{"fn_nam(...TRUNCATED)
0
1
13
1
6
[{"content":"Solve the programming task below in a Python markdown code block.\n\nA subarray is a co(...TRUNCATED)
[{"content":"```python\nimport sys\ninput = sys.stdin.readline\n\nt = int(input())\nfor _ in range(t(...TRUNCATED)
deepcoder
0
64,550.00186
5.927801
64,555.929661
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":6,"verification_info":{"fn_nam(...TRUNCATED)
0
0
13
0.615385
7
[{"content":"Solve the programming task below in a Python markdown code block.\n\nYarik is a big fan(...TRUNCATED)
[{"content":"```python\nimport sys\ninput = sys.stdin.readline\n\nt = int(input())\nfor _ in range(t(...TRUNCATED)
deepcoder
1
71,832.580566
0.171423
71,832.751989
{"num_test_cases":13,"source":"lcbv5","subset":"i3-code","subset_idx":7,"verification_info":{"fn_nam(...TRUNCATED)
0
1
13
1
8
[{"content":"Solve the programming task below in a Python markdown code block.\n\nYou are given a 0-(...TRUNCATED)
[{"content":"```python\nfrom typing import List\n\nclass Solution:\n def countSeniors(self, detai(...TRUNCATED)
deepcoder
1
73,787.504196
0.208855
73,787.713051
{"num_test_cases":14,"source":"lcbv5","subset":"i3-code","subset_idx":8,"verification_info":{"fn_nam(...TRUNCATED)
0
1
14
1
9
[{"content":"Solve the programming task below in a Python markdown code block.\n\nYou are given a 0-(...TRUNCATED)
[{"content":"```python\nfrom typing import List\n\nclass Solution:\n def matrixSum(self, nums: Li(...TRUNCATED)
deepcoder
1
87,828.227282
0.221968
87,828.449249
{"num_test_cases":14,"source":"lcbv5","subset":"i3-code","subset_idx":9,"verification_info":{"fn_nam(...TRUNCATED)
0
1
14
1
End of preview. Expand in Data Studio
README.md exists but content is empty.
Downloads last month
11