Dataset Viewer
Auto-converted to Parquet Duplicate
id
stringlengths
22
22
domain
stringclasses
1 value
dataset
stringclasses
1 value
split
stringclasses
1 value
index
int64
0
10k
prompt
stringlengths
242
8.19k
verifier_type
stringclasses
1 value
verifier_data
dict
metadata
dict
code_taco_stdin_013353
code
code
train
0
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Santa Claus is the first who came to the Christmas Olympiad, and he is going to be the first to take his place at a desk! In ...
code_exec
{ "test_cases": [ { "input": "4 3 9\n", "output": "2 2 L\n" }, { "input": "4 3 24\n", "output": "4 3 R\n" }, { "input": "2 4 4\n", "output": "1 2 R\n" }, { "input": "3 10 24\n", "output": "2 2 R\n" }, { "input": "10 3 59\n", ...
{ "original_source": "TACO-verified", "original_id": 13353, "difficulty": "EASY", "source": "codeforces", "tags": "['Mathematics', 'Implementation']", "raw_tags": "['math', 'implementation']", "url": "https://codeforces.com/problemset/problem/748/A", "solution": "(n, m, k) = map(int, input().split())\nq...
code_taco_stdin_025108
code
code
train
1
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Read problems statements in mandarin chinese, russian and vietnamese as well. Today is the final round of La Liga, the most...
code_exec
{ "test_cases": [ { "input": "2\nBarcelona 2\nMalaga 1\nRealMadrid 1\nEibar 0\nMalaga 3\nRealMadrid 2\nBarcelona 8\nEibar 6", "output": "RealMadrid\nBarcelona" } ] }
{ "original_source": "TACO-verified", "original_id": 25108, "difficulty": "EASY", "source": "codechef", "tags": "[]", "raw_tags": "['deadwing97', 'cakewalk', 'cook82']", "url": "https://www.codechef.com/problems/COOK82A", "solution": "T = int(input())\nfor i in range(T):\n\tscores = dict()\n\tfor j in r...
code_taco_stdin_025282
code
code
train
2
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: You are given a string $s$. You have to determine whether it is possible to build the string $s$ out of strings aa, aaa, bb a...
code_exec
{ "test_cases": [ { "input": "8\naaaabbb\nbbaaaaabbb\naaaaaa\nabab\na\nb\naaaab\nbbaaa\n", "output": "YES\nYES\nYES\nNO\nNO\nNO\nNO\nYES\n" }, { "input": "1\nabababababababababababababababababababababababab\n", "output": "NO\n" } ] }
{ "original_source": "TACO-verified", "original_id": 25282, "difficulty": "EASY", "source": "codeforces", "tags": "['Implementation']", "raw_tags": "['implementation']", "url": "https://codeforces.com/problemset/problem/1671/A", "solution": "def solve(s):\n\tans = 'YES'\n\tarr = []\n\tcurr = 0\n\tlast =...
code_taco_stdin_017708
code
code
train
3
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: A left rotation operation on an array of size $n$ shifts each of the array's elements $1$ unit to the left. Given an integer,...
code_exec
{ "test_cases": [ { "input": "5 4\n1 2 3 4 5\n", "output": "5 1 2 3 4\n" } ] }
{ "original_source": "TACO-verified", "original_id": 17708, "difficulty": "EASY", "source": "hackerrank", "tags": "['Data structures']", "raw_tags": "['Data Structures - Arrays']", "url": "https://www.hackerrank.com/challenges/array-left-rotation/problem", "solution": "(n, d) = map(int, input().split())...
code_taco_stdin_000747
code
code
train
4
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You ...
code_exec
{ "test_cases": [ { "input": "4\n6 5 6 8\n", "output": "3\n" }, { "input": "5\n4 5 3 5 4\n", "output": "3\n" }, { "input": "5\n9 5 6 8 4\n", "output": "1\n" }, { "input": "2\n75 26\n", "output": "1\n" }, { "input": "20\n45 72 81...
{ "original_source": "TACO-verified", "original_id": 747, "difficulty": "EASY", "source": "atcoder", "tags": "[]", "raw_tags": "[]", "url": "https://atcoder.jp/contests/abc124/tasks/abc124_b", "solution": "n = int(input())\nh = list(map(int, input().split()))\nkei = 1\nm = h[0]\nfor i in range(1, n):\n\...
code_taco_stdin_016348
code
code
train
5
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Polycarp analyzes the prices of the new berPhone. At his disposal are the prices for $n$ last days: $a_1, a_2, \dots, a_n$, w...
code_exec
{ "test_cases": [ { "input": "5\n6\n3 9 4 6 7 5\n1\n1000000\n2\n2 1\n10\n31 41 59 26 53 58 97 93 23 84\n7\n3 2 1 2 3 4 5\n", "output": "3\n0\n1\n8\n2\n" }, { "input": "5\n6\n3 9 4 6 7 5\n1\n1000000\n2\n2 0\n10\n31 41 59 26 53 58 97 93 23 84\n7\n3 2 1 2 3 4 5\n", "output": "3\n0\n1\...
{ "original_source": "TACO-verified", "original_id": 16348, "difficulty": "EASY", "source": "codeforces", "tags": "['Data structures', 'Implementation']", "raw_tags": "['data structures', 'implementation']", "url": "https://codeforces.com/problemset/problem/1213/B", "solution": "from collections import ...
code_taco_stdin_007794
code
code
train
6
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: A new delivery of clothing has arrived today to the clothing store. This delivery consists of $a$ ties, $b$ scarves, $c$ vest...
code_exec
{ "test_cases": [ { "input": "4\n5\n6\n3\n1\n2\n", "output": "6\n" }, { "input": "12\n11\n13\n20\n4\n6\n", "output": "102\n" }, { "input": "17\n14\n5\n21\n15\n17\n", "output": "325\n" }, { "input": "43475\n48103\n50473\n97918\n991\n974\n", "o...
{ "original_source": "TACO-verified", "original_id": 7794, "difficulty": "EASY", "source": "codeforces", "tags": "['Complete search', 'Mathematics', 'Greedy algorithms']", "raw_tags": "['brute force', 'greedy', 'math']", "url": "https://codeforces.com/problemset/problem/1271/A", "solution": "a = int(inp...
code_taco_stdin_023641
code
code
train
7
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Mr. Anant Asankhya is the manager at the INFINITE hotel. The hotel has an infinite amount of rooms. One fine day, a finite ...
code_exec
{ "test_cases": [ { "input": "5\n1 2 3 6 5 4 4 2 5 3 6 1 6 5 3 2 4 1 2 5 1 4 3 6 8 4 3 1 5 6 2 \n", "output": "8\n" } ] }
{ "original_source": "TACO-verified", "original_id": 23641, "difficulty": "EASY", "source": "hackerrank", "tags": "['Data structures']", "raw_tags": "['Python - Sets']", "url": "https://www.hackerrank.com/challenges/py-the-captains-room/problem", "solution": "from collections import Counter\nK = int(inp...
code_taco_stdin_024898
code
code
train
8
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: During their New Year holidays, Alice and Bob play the following game using an array $a$ of $n$ integers: Players take turns...
code_exec
{ "test_cases": [ { "input": "4\n4\n5 2 7 3\n3\n3 2 1\n4\n2 2 2 2\n2\n7 8\n", "output": "Bob\nTie\nAlice\nAlice\n" }, { "input": "2\n3\n1 1 234872\n4\n5 2 7 3\n", "output": "Alice\nBob\n" }, { "input": "2\n3\n1 1 234872\n4\n5 2 7 3\n", "output": "Alice\nBob\n" ...
{ "original_source": "TACO-verified", "original_id": 24898, "difficulty": "EASY", "source": "codeforces", "tags": "['Dynamic programming', 'Sorting', 'Game theory', 'Greedy algorithms']", "raw_tags": "['games', 'greedy', 'sortings', 'dp']", "url": "https://codeforces.com/problemset/problem/1472/D", "sol...
code_taco_stdin_019426
code
code
train
9
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: A non-empty string is called palindrome, if it reads the same from the left to the right and from the right to the left. For ...
code_exec
{ "test_cases": [ { "input": "6\nmsucmc\n", "output": "ccmmsu\n" }, { "input": "2\naa\n", "output": "aa\n" }, { "input": "15\nabacabadabacaba\n", "output": "aaaaaaaabbbbccd\n" }, { "input": "21\narozaupalanalapuazora\n", "output": "aaaaaaaall...
{ "original_source": "TACO-verified", "original_id": 19426, "difficulty": "EASY", "source": "codeforces", "tags": "['String algorithms', 'Constructive algorithms']", "raw_tags": "['strings', 'constructive algorithms']", "url": "https://codeforces.com/problemset/problem/1064/C", "solution": "input()\npri...
code_taco_stdin_019245
code
code
train
10
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Manasa is out on a hike with friends. She finds a trail of stones with numbers on them. She starts following the trail and no...
code_exec
{ "test_cases": [ { "input": "2 \n3 \n1 \n2 \n4 \n10 \n100 \n", "output": "2 3 4 \n30 120 210 300 \n" } ] }
{ "original_source": "TACO-verified", "original_id": 19245, "difficulty": "EASY", "source": "hackerrank", "tags": "['Implementation']", "raw_tags": "['Algorithms - Implementation']", "url": "https://www.hackerrank.com/challenges/manasa-and-stones/problem", "solution": "import sys\nt = int(input())\nfor ...
code_taco_stdin_011057
code
code
train
11
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: In computing, the collection of four bits is called a nibble. Chef defines a program as: Good, if it takes exactly X nibbles...
code_exec
{ "test_cases": [ { "input": "4\n8\n17\n52\n3", "output": "Good\nNot Good\nGood\nNot Good" } ] }
{ "original_source": "TACO-verified", "original_id": 11057, "difficulty": "EASY", "source": "codechef", "tags": "['Number theory', 'Mathematics']", "raw_tags": "['Mathematics', 'Basic Maths', 'Divisibility', 'Integer Division', 'Modular Arithmetic']", "url": "https://www.codechef.com/problems/NIBBLE", "...
code_taco_stdin_007621
code
code
train
12
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Given a sorted doubly linked list and an element X, your need to insert the element X into correct position in the sorted DLL...
code_exec
{ "test_cases": [ { "input": "LinkedList:\r\n\r\nX = 9", "output": "" } ] }
{ "original_source": "TACO-verified", "original_id": 7621, "difficulty": "EASY", "source": "geeksforgeeks", "tags": "['Data structures']", "raw_tags": "['Data Structures', 'doubly-linked-list', 'Linked List']", "url": "https://practice.geeksforgeeks.org/problems/insert-in-sorted-way-in-a-sorted-dll/1", ...
code_taco_stdin_010522
code
code
train
13
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Mario transforms each time he eats a mushroom as follows: If he is currently small, he turns normal. If he is currently norma...
code_exec
{ "test_cases": [ { "input": "3\n2\n4\n12", "output": "SMALL\nHUGE\nNORMAL" } ] }
{ "original_source": "TACO-verified", "original_id": 10522, "difficulty": "EASY", "source": "codechef", "tags": "[]", "raw_tags": "['Algorithms', 'Observation']", "url": "https://www.codechef.com/problems/TRANSFORM", "solution": "t = int(input())\nfor i in range(t):\n\tx = int(input())\n\tif x % 3 == 1:...
code_taco_stdin_003685
code
code
train
14
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Let's denote d(n) as the number of divisors of a positive integer n. You are given three integers a, b and c. Your task is to...
code_exec
{ "test_cases": [ { "input": "2 2 2\n", "output": "20\n" }, { "input": "5 6 7\n", "output": "1520\n" }, { "input": "91 42 25\n", "output": "3076687\n" }, { "input": "38 47 5\n", "output": "160665\n" }, { "input": "82 29 45\n", ...
{ "original_source": "TACO-verified", "original_id": 3685, "difficulty": "EASY", "source": "codeforces", "tags": "['Number theory', 'Implementation']", "raw_tags": "['number theory', 'implementation']", "url": "https://codeforces.com/problemset/problem/236/B", "solution": "(a, b, c) = map(int, input().s...
code_taco_stdin_019383
code
code
train
15
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: You are given a $sorted$ list $A$ of size $N$.You have to make a new list $B$ such that $B[i]$ is equal to the number of ele...
code_exec
{ "test_cases": [ { "input": "2\n4\n1 2 4 4\n5\n1 2 2 2 2", "output": "3 2 0 0\n4 0 0 0 0" } ] }
{ "original_source": "TACO-verified", "original_id": 19383, "difficulty": "EASY", "source": "codechef", "tags": "['Sorting', 'Complete search']", "raw_tags": "['Algorithms', 'Brute Force', 'Sorting']", "url": "https://www.codechef.com/problems/BIT2A", "solution": "goals = int(input())\nfor distractions ...
code_taco_stdin_008624
code
code
train
16
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Little penguin Polo adores integer segments, that is, pairs of integers [l; r] (l ≤ r). He has a set that consists of n int...
code_exec
{ "test_cases": [ { "input": "2 3\n1 2\n3 4\n", "output": "2\n" }, { "input": "3 7\n1 2\n3 3\n4 7\n", "output": "0\n" }, { "input": "3 7\n1 10\n11 47\n74 128\n", "output": "3\n" }, { "input": "5 4\n1 1\n2 2\n3 3\n4 4\n5 5\n", "output": "3\n" ...
{ "original_source": "TACO-verified", "original_id": 8624, "difficulty": "EASY", "source": "codeforces", "tags": "['Implementation', 'Complete search']", "raw_tags": "['brute force', 'implementation']", "url": "https://codeforces.com/problemset/problem/289/A", "solution": "(n, k) = input().split()\nL = ...
code_taco_stdin_017719
code
code
train
17
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Dawid has four bags of candies. The i-th of them contains a_i candies. Also, Dawid has two friends. He wants to give each bag...
code_exec
{ "test_cases": [ { "input": "26 52 7 19\n", "output": "YES\n" }, { "input": "1 2 3 4\n", "output": "YES\n" }, { "input": "1 1 2 3\n", "output": "NO\n" }, { "input": "7 3 6 3\n", "output": "NO\n" }, { "input": "5 10 1 6\n", ...
{ "original_source": "TACO-verified", "original_id": 17719, "difficulty": "EASY", "source": "codeforces", "tags": "['Implementation', 'Complete search']", "raw_tags": "['brute force', 'implementation']", "url": "https://codeforces.com/problemset/problem/1231/A", "solution": "(a1, a2, a3, a4) = map(int, ...
code_taco_stdin_010923
code
code
train
18
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Chef has a bucket having a capacity of K liters. It is already filled with X liters of water. Find the maximum amount of ex...
code_exec
{ "test_cases": [ { "input": "2\n5 4\n15 6\n", "output": "1\n9\n" } ] }
{ "original_source": "TACO-verified", "original_id": 10923, "difficulty": "EASY", "source": "codechef", "tags": "['Mathematics']", "raw_tags": "['Mathematics', 'Basic Maths', 'Arithmetic']", "url": "https://www.codechef.com/problems/FBC", "solution": "t = int(input())\nfor i in range(t):\n\t(n, m) = map...
code_taco_stdin_013991
code
code
train
19
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: You are given a multiset $S$ initially consisting of $n$ distinct non-negative integers. A multiset is a set, that can contai...
code_exec
{ "test_cases": [ { "input": "5\n4 1\n0 1 3 4\n3 1\n0 1 4\n3 0\n0 1 4\n3 2\n0 1 2\n3 2\n1 2 3\n", "output": "4\n4\n3\n5\n3\n" }, { "input": "7\n5 1000000000\n4 2 3 0 1\n4 0\n5 2 0 1\n3 0\n100 0 1\n6 1234567\n1 2 3 4 5 0\n3 114514\n8 0 4\n1 1000000\n0\n1 10000000\n1\n", "output": "1...
{ "original_source": "TACO-verified", "original_id": 13991, "difficulty": "EASY", "source": "codeforces", "tags": "['Mathematics']", "raw_tags": "['math']", "url": "https://codeforces.com/problemset/problem/1496/B", "solution": "for _ in range(int(input())):\n\t(n, k) = map(int, input().split())\n\ta = ...
code_taco_stdin_008281
code
code
train
20
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Blake is a CEO of a large company called "Blake Technologies". He loves his company very much and he thinks that his company ...
code_exec
{ "test_cases": [ { "input": "5\n1 2 4 3 2\n2 3 3 12 1\n", "output": "22" }, { "input": "10\n13 2 7 11 8 4 9 8 5 1\n5 7 18 9 2 3 0 11 8 6\n", "output": "46" }, { "input": "25\n12 30 38 109 81 124 80 33 38 48 29 78 96 48 96 27 80 77 102 65 80 113 31 118 35\n25 64 95 13...
{ "original_source": "TACO-verified", "original_id": 8281, "difficulty": "EASY", "source": "codeforces", "tags": "['Implementation', 'Complete search']", "raw_tags": "['brute force', 'implementation']", "url": "https://codeforces.com/problemset/problem/631/A", "solution": "from functools import reduce\n...
code_taco_stdin_012394
code
code
train
21
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: PizzaForces is Petya's favorite pizzeria. PizzaForces makes and sells pizzas of three sizes: small pizzas consist of $6$ slic...
code_exec
{ "test_cases": [ { "input": "6\n12\n15\n300\n1\n9999999999999999\n3\n", "output": "30\n40\n750\n15\n25000000000000000\n15\n" }, { "input": "1\n100002\n", "output": "250005\n" }, { "input": "1\n13594805\n", "output": "33987015\n" }, { "input": "1\n...
{ "original_source": "TACO-verified", "original_id": 12394, "difficulty": "EASY", "source": "codeforces", "tags": "['Mathematics', 'Complete search']", "raw_tags": "['brute force', 'math']", "url": "https://codeforces.com/problemset/problem/1555/A", "solution": "for s in [*open(0)][1:]:\n\tprint(max(6, ...
code_taco_stdin_003534
code
code
train
22
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Ela loves reading a lot, just like her new co-workers in DTL! On her first day after becoming an engineer in DTL, she is chal...
code_exec
{ "test_cases": [ { "input": "5\n12 3\ncabccadabaac\n12 6\ncabccadabaac\n12 12\ncabccadabaac\n25 1\nabcdefghijklmnopqrstuvwxy\n10 5\nbcdxedbcfg\n", "output": "edb\nccbbba\nbbbbbaaaaaaa\nz\naaaaa\n" }, { "input": "1\n18 3\naaaaaaaaaaaaaaaaaa\n", "output": "bbb\n" }, { ...
{ "original_source": "TACO-verified", "original_id": 3534, "difficulty": "EASY", "source": "codeforces", "tags": "['String algorithms', 'Implementation', 'Greedy algorithms']", "raw_tags": "['greedy', 'strings', 'implementation']", "url": "https://codeforces.com/problemset/problem/1737/A", "solution": "...
code_taco_stdin_018826
code
code
train
23
Write a complete executable Python 3 program that solves the problem. Read all input from standard input and print the answer to standard output. Return code only, with no explanation. Problem: Chef is trying to solve a problem having T test cases, where, for each test case he is given a single integer N. Chef has an...
code_exec
{ "test_cases": [ { "input": "4\n10 100 200\n3 10 100\n1000 1000 2200\n100 100 100\n", "output": "20000\n300\n2040000\n10000\n" } ] }
{ "original_source": "TACO-verified", "original_id": 18826, "difficulty": "EASY", "source": "codechef", "tags": "['Mathematics']", "raw_tags": "['Mathematics']", "url": "https://www.codechef.com/problems/SLOWSOLN", "solution": "for _ in range(int(input())):\n\t(t, n, sn) = map(int, input().split())\n\ta...
End of preview. Expand in Data Studio

No dataset card yet

Downloads last month
27