Datasets:
task_id stringlengths 21 21 | prompt stringlengths 229 6.27k | starter_code stringclasses 1
value | reference_solution stringlengths 32 11.4k | tests dict | source stringclasses 1
value | difficulty stringclasses 28
values | metadata dict |
|---|---|---|---|---|---|---|---|
task_b1b8782595db7c4a | Polycarp has $$$n$$$ coins, the value of the $$$i$$$-th coin is $$$a_i$$$. Polycarp wants to distribute all the coins between his pockets, but he cannot put two coins with the same value into the same pocket.
For example, if Polycarp has got six coins represented as an array $$$a = [1, 2, 4, 3, 3, 2]$$$, he can distri... | We have to find the maximum number of elements with the same value (it can be done by counting). This number will be the answer because if there are no more than $$$k$$$ elements with the same value in the array it is obvious that we cannot use less than $$$k$$$ pockets, but we also doesn't need to use more than $$$k$$... | {
"asserts": [],
"fn_name": null,
"inputs": [
"6\r\n1 2 4 3 3 2\r\n",
"1\r\n100\r\n",
"100\r\n100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 ... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1003",
"contest_name": "Codeforces Round 494 (Div. 3)",
"contest_start": 1530628500,
"contest_start_year": 2018,
"contest_type": "ICPC",
"dataset_index": 3185,
"description": "Polycarp has $$$n$$$ coins, the ... | |
task_7d018daf578a2dc3 | There is a beautiful garden of stones in Innopolis.
Its most beautiful place is the $$$n$$$ piles with stones numbered from $$$1$$$ to $$$n$$$.
EJOI participants have visited this place twice.
When they first visited it, the number of stones in piles was $$$x_1, x_2, \ldots, x_n$$$, correspondingly. One of the parti... | It can be simply showed that the answer is «Yes» if and only if the sum in the first visit is not less than the sum in the second visit. | {
"asserts": [],
"fn_name": null,
"inputs": [
"5\r\n1 2 3 4 5\r\n2 1 4 3 5\r\n",
"5\r\n1 1 1 1 1\r\n1 0 1 0 1\r\n",
"3\r\n2 3 9\r\n1 7 9\r\n",
"40\r\n361 372 139 808 561 460 421 961 727 719 130 235 320 470 432 759 317 886 624 666 917 133 736 710 462 424 541 118 228 216 612 339 800 557 291 128 801 ... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1013",
"contest_name": "Codeforces Round 500 (Div. 2) [based on EJOI]",
"contest_start": 1532938500,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 2058,
"description": "There is a beautif... | |
task_ec4866771f5e25ad | You have a plate and you want to add some gilding to it. The plate is a rectangle that we split into $$$w\times h$$$ cells. There should be $$$k$$$ gilded rings, the first one should go along the edge of the plate, the second one — $$$2$$$ cells away from the edge and so on. Each ring has a width of $$$1$$$ cell. Forma... | The number of gilded cells in the first (outer) ring is the number of border cells, that is, $$$2(w + h) - 4$$$, in the second ring — the number of border cells of the center rectangle with side lengths 4 less, that is, $$$2(w - 4 + h - 4) - 4$$$, and so on. This sum can be calculated in a single loop. | {
"asserts": [],
"fn_name": null,
"inputs": [
"3 3 1\r\n",
"7 9 1\r\n",
"7 9 2\r\n",
"18 26 3\r\n",
"63 34 8\r\n",
"100 100 25\r\n",
"4 3 1\r\n",
"3 4 1\r\n",
"3 10 1\r\n",
"12 3 1\r\n",
"4 4 1\r\n",
"10 4 1\r\n",
"4 12 1\r\n",
"10 10 1\r\n",
"10 10 2\r\... | open-r1/codeforces | 800 | {
"aliases": [
"1072/A"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1031",
"contest_name": "Technocup 2019 - Elimination Round 2",
"contest_start": 1540109400,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 6469,
"description": "You have a pl... | |
task_a4d7f99a3b42e0ba | Masha lives in a multi-storey building, where floors are numbered with positive integers. Two floors are called adjacent if their numbers differ by one. Masha decided to visit Egor. Masha lives on the floor $$$x$$$, Egor on the floor $$$y$$$ (not on the same floor with Masha).
The house has a staircase and an elevator... | The time needed if we use stairs is $$$|x - y| \cdot t_1$$$.
The time needed if we use elevator is $$$|z - x| \cdot t_2 + |x - y| \cdot t_2 + 3 \cdot t_3$$$.
We can simply compute this values and compare them.
Time complexity: $$$O(1)$$$. | {
"asserts": [],
"fn_name": null,
"inputs": [
"5 1 4 4 2 1\r\n",
"1 6 6 2 1 1\r\n",
"4 1 7 4 1 2\r\n",
"749 864 931 266 94 891\r\n",
"719 137 307 244 724 777\r\n",
"608 11 980 338 208 78\r\n",
"571 695 153 288 64 421\r\n",
"837 544 703 808 549 694\r\n",
"271 634 606 95 39 523\r... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1054",
"contest_name": "Mail.Ru Cup 2018 Round 1",
"contest_start": 1539880500,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 4066,
"description": "Masha lives in a multi-storey building,... | |
task_4b52d3f3a9e0287b | You have unlimited number of coins with values $$$1, 2, \ldots, n$$$. You want to select some set of coins having the total value of $$$S$$$.
It is allowed to have multiple coins with the same value in the set. What is the minimum number of coins required to get sum $$$S$$$?
Input format:
The only line of the input c... | Notice that using maximum value coin whenever possible will be always optimal. Hence, we can use $$$floor(S / n)$$$ coins of value $$$n$$$. Now, if $$$S \mod n$$$ is not equal to $$$0$$$, then we need to use one more coin of valuation $$$S \mod n$$$. Hence, our answer can be written as $$$ceil(S / n)$$$.
Overall Comple... | {
"asserts": [],
"fn_name": null,
"inputs": [
"5 11\r\n",
"6 16\r\n",
"14 28\r\n",
"5 29\r\n",
"10 24\r\n",
"1 30\r\n",
"14969 66991573\r\n",
"1 1000000000\r\n",
"100000 1\r\n",
"10 46\r\n",
"11 35\r\n",
"12 45\r\n",
"15 34\r\n",
"31859 629091638\r\n",
"... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 2.0 s\nMemory limit: 256.0 MB",
"contest_id": "1061",
"contest_name": "Codeforces Round 523 (Div. 2)",
"contest_start": 1542901500,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 3574,
"description": "You have unlimited number of coins... | |
task_233441591879df58 | Masha has three sticks of length $$$a$$$, $$$b$$$ and $$$c$$$ centimeters respectively. In one minute Masha can pick one arbitrary stick and increase its length by one centimeter. She is not allowed to break sticks.
What is the minimum number of minutes she needs to spend increasing the stick's length in order to be a... | Suppose $$$c$$$ is the largest stick. It is known, that we can build a triangle iff $$$c \le a + b - 1$$$.
So if we can build a triangle the answer is zero. Otherwise we can just increase $$$a$$$ or $$$b$$$ until the inequality above holds.
So the answer is $$$max(0, c - (a + b - 1))$$$.
Another approach: just brutefor... | {
"asserts": [],
"fn_name": null,
"inputs": [
"3 4 5\r\n",
"2 5 3\r\n",
"100 10 10\r\n",
"1 1 1\r\n",
"100 100 100\r\n",
"100 1 1\r\n",
"12 34 56\r\n",
"68 1 67\r\n",
"100 100 1\r\n",
"100 1 99\r\n",
"23 56 33\r\n",
"98 12 23\r\n",
"88 2 6\r\n",
"1 50 87\r\n... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 2.0 s\nMemory limit: 256.0 MB",
"contest_id": "1064",
"contest_name": "Codeforces Round 516 (Div. 2, by Moscow Team Olympiad)",
"contest_start": 1539511500,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 811,
"description": "Masha has ... | |
task_ff7f815cc08688b6 | On a chessboard with a width of $$$n$$$ and a height of $$$n$$$, rows are numbered from bottom to top from $$$1$$$ to $$$n$$$, columns are numbered from left to right from $$$1$$$ to $$$n$$$. Therefore, for each cell of the chessboard, you can assign the coordinates $$$(r,c)$$$, where $$$r$$$ is the number of the row, ... | Let's find the minimum time needed for the white king to reach the coin.
It is obvious that it is always optimal to move only towards the coin. In case of white king it means that we should move only up, right or up-right diagonally. During one move we can only add $$$1$$$ or $$$0$$$ to any of our coordinates (or to bo... | {
"asserts": [],
"fn_name": null,
"inputs": [
"4\r\n2 3\r\n",
"5\r\n3 5\r\n",
"2\r\n2 2\r\n",
"1000000000000000000\r\n1000000000000000000 1000000000000000000\r\n",
"1000000000000000000\r\n1 1\r\n",
"2\r\n1 1\r\n",
"1234567890123456\r\n1234567889969697 153760\r\n",
"12000000000000\r... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1075",
"contest_name": "Lyft Level 5 Challenge 2018 - Final Round (Open Div. 2)",
"contest_start": 1541355000,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 2887,
"description": "On a che... | |
task_002bb9e37e31e940 | Petya is having a party soon, and he has decided to invite his $$$n$$$ friends.
He wants to make invitations in the form of origami. For each invitation, he needs two red sheets, five green sheets, and eight blue sheets. The store sells an infinite number of notebooks of each color, but each notebook consists of only ... | Let's calculate how many notebooks we need for each color separately, and the answer, obviously, will be their sum. We need $$$2 \cdot n$$$ red sheets, $$$5 \cdot n$$$ green sheets, and $$$8 \cdot n$$$ blue sheets. So we need $$$\lceil \frac {2n}{k} \rceil$$$ notebooks with red sheets, $$$\lceil \frac{5n}{k} \rceil$$$ ... | {
"asserts": [],
"fn_name": null,
"inputs": [
"3 5\r\n",
"15 6\r\n",
"1 1\r\n",
"100000000 1\r\n",
"1 100000000\r\n",
"96865066 63740710\r\n",
"58064619 65614207\r\n",
"31115339 39163052\r\n",
"14231467 12711896\r\n",
"92314891 81228036\r\n",
"75431019 54776881\r\n",
... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1080",
"contest_name": "Codeforces Round 524 (Div. 2)",
"contest_start": 1543044900,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 2231,
"description": "Petya is having a party soon, and ... | |
task_0a7a58a1a50b6bf5 | Chouti was doing a competitive programming competition. However, after having all the problems accepted, he got bored and decided to invent some small games.
He came up with the following game. The player has a positive integer $$$n$$$. Initially the value of $$$n$$$ equals to $$$v$$$ and the player is able to do the ... | When $$$n \leq 2$$$, we can do nothing.
When $$$n \geq 3$$$, since $$$1<\frac{n}{n-1}<2$$$, $$$n-1$$$ isn't a divisor of $$$n$$$, so we can choose it and get $$$1$$$ as the result. | {
"asserts": [],
"fn_name": null,
"inputs": [
"8\r\n",
"1\r\n",
"4\r\n",
"3\r\n",
"158260522\r\n",
"2\r\n",
"1000000000\r\n",
"5\r\n",
"7\r\n",
"9\r\n",
"10\r\n",
"11\r\n",
"12\r\n",
"13\r\n",
"641009859\r\n",
"802593587\r\n"
],
"kind": "stdin_st... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1081",
"contest_name": "Avito Cool Challenge 2018",
"contest_start": 1544970900,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 1132,
"description": "Chouti was doing a competitive program... | |
task_5c5ccf0006268f0b | Polycarp loves ciphers. He has invented his own cipher called Right-Left.
Right-Left cipher is used for strings. To encrypt the string $$$s=s_{1}s_{2} \dots s_{n}$$$ Polycarp uses the following algorithm:
- he writes down $$$s_1$$$,
- he appends the current word with $$$s_2$$$ (i.e. writes down $$$s_2$$$ to the right... | You can simulate the process, maintaining the indices of characters of the initial string. So, like this you can find the value of character of the initial string. | {
"asserts": [],
"fn_name": null,
"inputs": [
"ncteho\r\n",
"erfdcoeocs\r\n",
"z\r\n",
"bz\r\n",
"tea\r\n",
"code\r\n",
"qwertyuioasdfghjklrtyuiodfghjklqwertyuioasdfssddxb\r\n",
"qwertyuioasdfghjklrtyuiodfghjklqwertyuioasdfssd\r\n",
"testa\r\n",
"abcdef\r\n",
"abcdefg\r... | open-r1/codeforces | 800 | {
"aliases": [
"1087/A"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1085",
"contest_name": "Technocup 2019 - Elimination Round 4",
"contest_start": 1545572100,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 1546,
"description": "Polycarp love... | |
task_58462edb27d78854 | Alice and Bob are decorating a Christmas Tree.
Alice wants only $$$3$$$ types of ornaments to be used on the Christmas Tree: yellow, blue and red. They have $$$y$$$ yellow ornaments, $$$b$$$ blue ornaments and $$$r$$$ red ornaments.
In Bob's opinion, a Christmas Tree will be beautiful if:
- the number of blue orname... | Consider some solution $$$Y$$$, $$$B$$$, $$$R$$$, where $$$Y + 1 = B$$$ and $$$B + 1 = R$$$. Let's add two yellow ornaments and one blue both to the solution and to the reserve, then we have $$$Y = B = R$$$. We can see that this new problem is equivalent to the old one. In this problem, the best solution is achieved wh... | {
"asserts": [],
"fn_name": null,
"inputs": [
"8 13 9\r\n",
"13 3 6\r\n",
"3 8 20\r\n",
"1 2 3\r\n",
"100 100 100\r\n",
"9 5 5\r\n",
"88 89 7\r\n",
"50 80 70\r\n",
"80 81 82\r\n",
"100 98 99\r\n",
"65 69 67\r\n",
"55 56 76\r\n",
"78 3 79\r\n",
"4 49 50\r\n",... | open-r1/codeforces | 800 | {
"aliases": [
"1171/B"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1091",
"contest_name": "Good Bye 2018",
"contest_start": 1546180500,
"contest_start_year": 2018,
"contest_type": "CF",
"dataset_index": 212,
"description": "Alice and Bob are decorating a Christ... | |
task_70f5d620ef4c42a3 | There are $$$n$$$ students in a university. The number of students is even. The $$$i$$$-th student has programming skill equal to $$$a_i$$$.
The coach wants to form $$$\frac{n}{2}$$$ teams. Each team should consist of exactly two students, and each student should belong to exactly one team. Two students can form a tea... | If we sort the students in order of non-decreasing their skill, we can see that the minimum cost of the team with the lowest skill (let's call it the first team) is equal to $$$a_2 - a_1$$$ (if $$$a$$$ is already sorted), the cost of the second team is $$$a_4 - a_3$$$ and so on.
So if we sort $$$a$$$ in non-decreasing ... | {
"asserts": [],
"fn_name": null,
"inputs": [
"6\r\n5 10 2 3 14 5\r\n",
"2\r\n1 100\r\n",
"100\r\n15 14 32 65 28 96 33 93 48 28 57 20 32 20 90 42 57 53 18 58 94 21 27 29 37 22 94 45 67 60 83 23 20 23 35 93 3 42 6 46 68 46 34 25 17 16 50 5 49 91 23 76 69 100 58 68 81 32 88 41 64 29 37 13 95 25 6 59 74 ... | open-r1/codeforces | 800 | {
"aliases": [
"1532/D",
"1911/C"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1092",
"contest_name": "Codeforces Round 527 (Div. 3)",
"contest_start": 1545143700,
"contest_start_year": 2018,
"contest_type": "ICPC",
"dataset_index": 5309,
"description": "Ther... | |
task_5c9cafdb9c9276d6 | Polycarp loves ciphers. He has invented his own cipher called repeating.
Repeating cipher is used for strings. To encrypt the string $$$s=s_{1}s_{2} \dots s_{m}$$$ ($$$1 \le m \le 10$$$), Polycarp uses the following algorithm:
- he writes down $$$s_1$$$ ones,
- he writes down $$$s_2$$$ twice,
- he writes down $$$s_3$... | There are many possible approaches in this problem, I will describe one of the easiest.
Let's print the initial string by the following algorithm: firstly, init the variable $$$i = 1$$$. Then, while the encrypted string isn't empty, print the first character of this string, remove $$$i$$$ first characters from it and i... | {
"asserts": [],
"fn_name": null,
"inputs": [
"6\r\nbaabbb\r\n",
"10\r\nooopppssss\r\n",
"1\r\nz\r\n",
"3\r\nzww\r\n",
"55\r\ncooooonnnnttttteeeeeeeeeeeeessssssssttttttttttttttttttt\r\n",
"21\r\ncoodddeeeecccccoooooo\r\n",
"55\r\naaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\... | open-r1/codeforces | 800 | {
"aliases": [
"1911/B"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1095",
"contest_name": "Codeforces Round 529 (Div. 3)",
"contest_start": 1545921300,
"contest_start_year": 2018,
"contest_type": "ICPC",
"dataset_index": 537,
"description": "Polycarp loves ciph... | |
task_018f9375ef43dc98 | Gennady owns a small hotel in the countryside where he lives a peaceful life. He loves to take long walks, watch sunsets and play cards with tourists staying in his hotel. His favorite game is called "Mau-Mau".
To play Mau-Mau, you need a pack of $$$52$$$ cards. Each card has a suit (Diamonds — D, Clubs — C, Spades — ... | The task is to check if some card in the second line has a common character with the card in the first line. The best way to do this is to create a single string for the card in the hand and an array of strings for the cards on the table.
After reading the input, just iterate with a loop over the array. If a string in ... | {
"asserts": [],
"fn_name": null,
"inputs": [
"AS\r\n2H 4C TH JH AD\r\n",
"2H\r\n3D 4C AC KD AS\r\n",
"4D\r\nAS AC AD AH 5H\r\n",
"3D\r\n8S 4S 2C AS 6H\r\n",
"7H\r\nTC 4C KC AD 9S\r\n",
"KH\r\n3C QD 9S KS 8D\r\n",
"4H\r\nJH QC 5H 9H KD\r\n",
"9H\r\nKC 6D KD 4C 2S\r\n",
"AD\r\nQ... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1097",
"contest_name": "Hello 2019",
"contest_start": 1546613100,
"contest_start_year": 2019,
"contest_type": "CF",
"dataset_index": 6795,
"description": "Gennady owns a small hotel in the countryside where h... | |
task_4f2fdfab78466566 | Today's morning was exceptionally snowy. Meshanya decided to go outside and noticed a huge snowball rolling down the mountain! Luckily, there are two stones on that mountain.
Initially, snowball is at height $$$h$$$ and it has weight $$$w$$$. Each second the following sequence of events happens: snowball's weights inc... | This problem can be solved in many ways, we will tell you one of them. Let's just iterate through all the heights of $$$i$$$ from $$$h$$$ to $$$1$$$. Inside the loop, we have to add $$$i$$$ to the weight of snowball, and then check whether there is a stone at this height. If there is, then you need to check whether wei... | {
"asserts": [],
"fn_name": null,
"inputs": [
"4 3\r\n1 1\r\n1 2\r\n",
"4 3\r\n9 2\r\n0 1\r\n",
"41 2\r\n1 1\r\n67 2\r\n",
"87 2\r\n10 2\r\n76 1\r\n",
"94 3\r\n71 3\r\n12 2\r\n",
"30 2\r\n88 1\r\n2 2\r\n",
"8 2\r\n29 1\r\n23 2\r\n",
"85 3\r\n47 1\r\n92 3\r\n",
"34 5\r\n82 2\r\n... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1099",
"contest_name": "Codeforces Round 530 (Div. 2)",
"contest_start": 1546706100,
"contest_start_year": 2019,
"contest_type": "CF",
"dataset_index": 1465,
"description": "Today's morning was exceptionally ... | |
task_63ca3e39b9c57b9f | You are given an integer sequence $$$1, 2, \dots, n$$$. You have to divide it into two sets $$$A$$$ and $$$B$$$ in such a way that each element belongs to exactly one set and $$$|sum(A) - sum(B)|$$$ is minimum possible.
The value $$$|x|$$$ is the absolute value of $$$x$$$ and $$$sum(S)$$$ is the sum of elements of the... | The first solution: take $$$n$$$ modulo $$$4$$$ and solve the problem manually (then for cases $$$n = 0$$$ and $$$n = 3$$$ the answer is $$$0$$$ and for $$$n = 1$$$ and $$$n = 2$$$ the answer is $$$1$$$).
Prove: Let's see what can we make for numbers $$$n$$$, $$$n - 1$$$, $$$n - 2$$$ and $$$n - 3$$$. We can add $$$n$$$... | {
"asserts": [],
"fn_name": null,
"inputs": [
"3\r\n",
"5\r\n",
"6\r\n",
"2000000000\r\n",
"1999999999\r\n",
"1999999997\r\n",
"1999999998\r\n",
"1\r\n",
"69420\r\n",
"999999998\r\n",
"65535\r\n",
"27397633\r\n",
"46341\r\n",
"1000271094\r\n",
"84457\r\n... | open-r1/codeforces | 800 | {
"aliases": null,
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1102",
"contest_name": "Codeforces Round 531 (Div. 3)",
"contest_start": 1547044500,
"contest_start_year": 2019,
"contest_type": "ICPC",
"dataset_index": 7114,
"description": "You are given an integer sequenc... | |
task_761a19ee51c95730 | For simplicity, we'll assume that there are only three types of grapes: green grapes, purple grapes and black grapes.
Andrew, Dmitry and Michal are all grapes' lovers, however their preferences of grapes are different. To make all of them happy, the following should happen:
- Andrew, Dmitry and Michal should eat at l... | First of all, we can see the grape preference is hierarchically inclusive: the grapes' types Andrew enjoys are some of those that Dmitry does, and Dmitry's favorites are included in Michal's.
Let's distribute the grapes to satisfy Andrew first, then to Dmitry, then Michal. If any of the following criteria is not satisf... | {
"asserts": [],
"fn_name": null,
"inputs": [
"1 6 2\r\n4 3 3\r\n",
"5 1 1\r\n4 3 2\r\n",
"1 1 100000\r\n4 2 99995\r\n",
"1 2 3\r\n3 2 1\r\n",
"1 8 4\r\n3 1 9\r\n",
"6 1 2\r\n4 9 6\r\n",
"100000 100000 100000\r\n100000 100000 100000\r\n",
"3 2 1\r\n1 2 3\r\n",
"99999 99998 9999... | open-r1/codeforces | 800 | {
"aliases": [
"1171/D"
],
"constraints": "Time limit: 1.0 s\nMemory limit: 256.0 MB",
"contest_id": "1114",
"contest_name": "Codeforces Round 538 (Div. 2)",
"contest_start": 1549807500,
"contest_start_year": 2019,
"contest_type": "CF",
"dataset_index": 1394,
"description": "For simplicity, we'l... |
End of preview. Expand in Data Studio
Codeforces Editorial ELO 512 - 2026-04-28
A 512-example subset sampled from open-r1/codeforces (verifiable, train) for Plan-CRL Codeforces feedback experiments that need a non-empty trusted reference field.
Important: open-r1/codeforces does not expose code reference solutions. This subset fills reference_solution from the source dataset's editorial field. Treat it as a natural-language editorial/rationale, not canonical reference code.
Selection seed: 20260428.
Filtering:
- rating present
- complete official tests
- stdio-only tasks
- no generated checker
- official tests present
- non-empty
editorial - eval
testscapped to 16 cases
Bucket balance:
elo_0800_0900: 128elo_1000_1500: 128elo_1600_2200: 128elo_2300_3500: 128
Useful fields for manual inspection:
promptreference_solution- copied fromeditorialtestsmetadata.ratingmetadata.elo_groupmetadata.reference_solution_sourcemetadata.titlemetadata.tags
Extra files:
metadata/selection_summary.jsonmetadata/selection_manifest.csv
- Downloads last month
- -