messages listlengths 1 1 | ground_truth stringlengths 88 726k | dataset stringclasses 2
values |
|---|---|---|
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N squares arranged in ... | [{"type": "stdin_stdout", "input": "9449\n43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505 43482505... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThe only difference between easy... | [{"type": "stdin_stdout", "input": "50 25\n199970 199997 199998 199988 199999 199981 200000 199990 199974 199985 199932 200000 199966 199999 199999 199951 199983 199975 199974 199996 199974 199992 199979 199995 199955 199989 199960 199975 199983 199990 199950 199952 199999 199999 199962 199939 199979 199977 199962 1999... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given the array $a$ cons... | [{"type": "stdin_stdout", "input": "8 6\n893967334 893967335 893967331 893967332 893967333 893967335 893967333 893967333\n", "output": "5\n"}, {"type": "stdin_stdout", "input": "21 6\n12 15 14 4 4 7 2 4 11 1 15 4 12 11 12 8 11 12 3 4 4\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "10 4\n1 2 3 5 5 5 5 10 11 1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi is practicing shiritor... | [{"type": "stdin_stdout", "input": "100\nlkykrymhey\nyujwmjhnzx\nxgmkqgsajk\nkkvqjyapln\nnkcubvbxdx\nxheccrzfne\neqeizvicxx\nxesnssfeuz\nzsjdhxndds\nsuvxanfkpe\neodirlsywl\nlmiwshvenl\nluomflsyiq\nqcjuajhxme\nelfadfvxvm\nmknedshbyv\nvnboqueaai\niwexnqgqvj\njzfofokvkg\nggzhwrtktd\nderapdnumy\nyfobbqcozo\noivhkngvyy\nytj... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi is organizing a party.... | [{"type": "stdin_stdout", "input": "100000 99999\n", "output": "9999900000\n"}, {"type": "stdin_stdout", "input": "90371 92227\n", "output": "8334646217\n"}, {"type": "stdin_stdout", "input": "59054 56588\n", "output": "1670873876\n"}, {"type": "stdin_stdout", "input": "51038 78188\n", "output": "1995279572\n"}, {"type... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven is a string S. Replace eve... | [{"type": "stdin_stdout", "input": "kvtvweokpottycaeeyfthzfvsgckwjmgqadfekjfitnsieylhumxjjezqvidkxjpywokrnzxxwraamuimhmrjwqeyvjvyjjzsxxf\n", "output": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n"}, {"type": "stdin_stdout", "input": "qvssniprlkdntynymqcjoxpttvp... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe will buy a product for N yen ... | [{"type": "stdin_stdout", "input": "1900\n", "output": "100\n"}, {"type": "stdin_stdout", "input": "1001\n", "output": "999\n"}, {"type": "stdin_stdout", "input": "4575\n", "output": "425\n"}, {"type": "stdin_stdout", "input": "6426\n", "output": "574\n"}, {"type": "stdin_stdout", "input": "9445\n", "output": "555\n"},... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nOur world is one-dimensional, an... | [{"type": "stdin_stdout", "input": "99 99 -22 62\n-9 -54 -13 -39 -79 -88 -6 -14 -41 -29 -2 -69 -30 -20 -33 -8 -24 -80 -19 -87 -32 -60 -40 -59 -44 -52 -3 -67 -18 -51 -56 -12 -7 -31 -48 -27 -68 -78 -21 -11 -49 -93 -1 -64 -82 -66 -70 -58 -84 -26 -57 -37 -53 -89 -50 -34 -61 -46 -92 -95 -99 -63 -65 -28 -10 -16 -73 -55 -98 -... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nEach day in Berland consists of ... | [{"type": "stdin_stdout", "input": "23\n1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "21\n1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "7\n1 0 1 1 1 0 1\n", "output": "3\n"}, {"type": "stdin_stdout", "input": "... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nLittle Petya wanted to give an A... | [{"type": "stdin_stdout", "input": "13\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "16\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "11\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "10\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "15\n", "output": "1\n"}, {"type": "stdin_std... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nNot to be confused with chessboa... | [{"type": "stdin_stdout", "input": "42\nquxukow soft\nwcn soft\npbwg soft\nlrp hard\nphdvfz soft\nidkvymji soft\nobq soft\nyhx soft\nijygw soft\nztzz soft\nuwdhnwu soft\ndgnuuej hard\nhntyyzr soft\nqxf hard\nztg soft\nhnpq soft\nuhznu soft\nitelgl hard\nggceadhw hard\nrxq soft\nkznmshem hard\nlri hard\ndalh soft\ngyzzu... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\n[Image] \n\n\n-----Input-----\n\... | [{"type": "stdin_stdout", "input": "0\n1\n1\n0\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "0\n0\n0\n0\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "1\n0\n0\n0\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "0\n1\n0\n0\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "1\n1\n0\n0\n... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi is meeting up with Aok... | [{"type": "stdin_stdout", "input": "7202 7775 4325\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "3982 4784 8417\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "2156 1932 5902\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "1 10000 10000\n", "output": "Yes\n"}, {"type": "stdin_stdout",... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have a bingo card with a 3\\t... | [{"type": "stdin_stdout", "input": "60 88 34\n92 41 43\n65 73 48\n10\n60\n43\n88\n11\n48\n73\n65\n41\n92\n34\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "100 99 20\n18 38 78\n76 60 1\n10\n5\n68\n38\n20\n19\n76\n60\n1\n78\n46\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "53 1 40\n16 75 35\n56 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi has N days of summer v... | [{"type": "stdin_stdout", "input": "1000000 10000\n10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000 10000... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nToday, the memorable AtCoder Beg... | [{"type": "stdin_stdout", "input": "2 100\n", "output": "1010000\n"}, {"type": "stdin_stdout", "input": "2 85\n", "output": "850000\n"}, {"type": "stdin_stdout", "input": "1 100\n", "output": "10100\n"}, {"type": "stdin_stdout", "input": "2 25\n", "output": "250000\n"}, {"type": "stdin_stdout", "input": "2 68\n", "outp... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi is a teacher responsib... | [{"type": "stdin_stdout", "input": "91\n13 42 58 64 76 15 46 37 62 71 25 14 3 61 2 75 44 45 65 74 79 48 41 72 1 10 73 8 63 83 47 36 40 33 87 7 23 38 54 28 60 29 35 57 80 5 11 43 66 50 30 21 12 20 19 51 27 82 69 70 4 68 89 78 17 18 67 26 91 56 9 53 49 32 6 39 84 22 88 59 55 86 24 34 81 85 52 77 31 90 16\n", "output": "2... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nN friends of Takahashi has come ... | [{"type": "stdin_stdout", "input": "81 358\n59 53 2 54 462 325 435 279 464 327 49 332 95 200 220 158 139 492 130 467 489 458 81 100 466 473 429 275 81 270 455 218 128 307 335 398 52 30 311 69 148 384 454 413 114 315 186 334 382 392 326 8 53 462 457 350 231 61 185 88 305 480 64 390 52 247 443 240 93 469 370 16 443 7 25 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have held a popularity poll f... | [{"type": "stdin_stdout", "input": "100 100\n1000 999 998 997 996 995 994 993 992 991 990 989 988 987 986 985 984 983 982 981 980 979 978 977 976 975 974 973 972 971 970 969 968 967 966 965 964 963 962 961 960 959 958 957 956 955 954 953 952 951 950 949 948 947 946 945 944 943 942 941 940 939 938 937 936 935 934 933 93... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have a grid of H rows and W c... | [{"type": "stdin_stdout", "input": "6 6 1\n#.....\n.#....\n..#...\n...#..\n....#.\n.....#\n", "output": "1458\n"}, {"type": "stdin_stdout", "input": "6 6 1\n#..#..\n#.....\n......\n......\n......\n.#....\n", "output": "1472\n"}, {"type": "stdin_stdout", "input": "6 6 1\n......\n......\n......\n..#...\n......\n......\n"... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given two non-negative i... | [{"type": "stdin_stdout", "input": "1999999216 1999999234\n", "output": "650\n"}, {"type": "stdin_stdout", "input": "1999999264 1999999270\n", "output": "26\n"}, {"type": "stdin_stdout", "input": "1999999266 1999999276\n", "output": "18\n"}, {"type": "stdin_stdout", "input": "1999997173 1999999190\n", "output": "0\n"},... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nPolycarp likes numbers that are ... | [{"type": "stdin_stdout", "input": "1000000000000000000000000000000000\n", "output": "33\n"}, {"type": "stdin_stdout", "input": "14139582796\n", "output": "6\n"}, {"type": "stdin_stdout", "input": "201920181\n", "output": "4\n"}, {"type": "stdin_stdout", "input": "10000170\n", "output": "5\n"}, {"type": "stdin_stdout",... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given two arrays $a$ and... | [{"type": "stdin_stdout", "input": "5\n-999999999 999999999 999999999 999999998 -999999999\n-999999999 -1000000000 -1000000000 -999999999 1000000000\n", "output": "3\n"}, {"type": "stdin_stdout", "input": "3\n999999999 999999998 999999999\n999999998 999999997 999999998\n", "output": "2\n"}, {"type": "stdin_stdout", "in... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are $n$ left boots and $n$... | [{"type": "stdin_stdout", "input": "20\nleduyanhyeunguyenhoa\nminhtriloveviethuong\n", "output": "10\n19 9\n10 14\n4 17\n13 20\n2 11\n1 8\n12 19\n8 4\n18 16\n7 3\n"}, {"type": "stdin_stdout", "input": "10\ncode??????\n??????test\n", "output": "10\n6 2\n1 6\n7 3\n3 5\n4 8\n9 7\n5 1\n2 4\n10 9\n8 10\n"}, {"type": "stdin_... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThis problem is given in two edi... | [{"type": "stdin_stdout", "input": "100\n1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given an array $a$, cons... | [{"type": "stdin_stdout", "input": "100 5\n5087 2232 2630 706 6716 9525 8018 1330 6689 2220 2486 7478 9225 8535 4099 3386 4392 8755 6088 2659 2129 8582 2784 2948 5336 6622 8559 2566 1733 1928 6090 8555 7673 7567 375 7468 1895 1036 4615 185 494 1306 2334 4238 8608 3721 1156 3326 7947 4401 4878 2372 3103 6884 1044 6281 1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere is an integer sequence A o... | [{"type": "stdin_stdout", "input": "100\n100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000 100000... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given an integer sequenc... | [{"type": "stdin_stdout", "input": "100\n3142445 16266949 17493698 35569790 80507149 98771888 109205766 111818374 116565925 119183522 141425056 157086378 180302992 187469083 216070266 233105051 257048184 265553444 273526101 281450237 289171706 301768399 311455945 319497119 326729809 338683702 339701654 346802542 353453... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N towns in a coordinat... | [{"type": "stdin_stdout", "input": "8\n898 1000\n85 1000\n980 1000\n359 1000\n-560 1000\n-764 1000\n-103 1000\n-116 1000\n", "output": "5277.7500000000\n"}, {"type": "stdin_stdout", "input": "8\n-1000 1000\n-1000 0\n-1000 -1000\n0 1000\n0 -1000\n1000 1000\n1000 0\n1000 -1000\n", "output": "12300.5630797458\n"}, {"type"... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThe window of Takahashi's room h... | [{"type": "stdin_stdout", "input": "100 100\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "75 25\n", "output": "25\n"}, {"type": "stdin_stdout", "input": "68 16\n", "output": "36\n"}, {"type": "stdin_stdout", "input": "20 15\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "20 30\n", "output": "0\n"}, ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given an integer N.\n\nF... | [{"type": "stdin_stdout", "input": "10000000000\n", "output": "6\n"}, {"type": "stdin_stdout", "input": "9999999967\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "9876543210\n", "output": "6\n"}, {"type": "stdin_stdout", "input": "6983776800\n", "output": "5\n"}, {"type": "stdin_stdout", "input": "1881548213... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nKatsusando loves omelette rice.\... | [{"type": "stdin_stdout", "input": "30 30\n30 18 27 26 17 24 6 29 5 10 4 16 2 30 14 12 3 11 19 1 21 28 20 23 15 25 9 8 7 22 13\n30 2 18 10 9 23 8 13 12 6 3 4 19 15 16 29 22 21 7 25 5 20 17 14 28 24 11 27 30 26 1\n30 18 23 13 19 10 2 12 21 11 28 1 17 26 27 22 29 14 3 15 9 8 5 6 25 30 16 20 7 24 4\n30 16 12 23 7 20 17 25... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven is an integer N.\nTakahash... | [{"type": "stdin_stdout", "input": "100\n", "output": "0.5000000000\n"}, {"type": "stdin_stdout", "input": "99\n", "output": "0.5050505051\n"}, {"type": "stdin_stdout", "input": "98\n", "output": "0.5000000000\n"}, {"type": "stdin_stdout", "input": "11\n", "output": "0.5454545455\n"}, {"type": "stdin_stdout", "input": ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N people numbered 1 to... | [{"type": "stdin_stdout", "input": "15\n14\n2 1\n3 1\n4 1\n5 1\n6 1\n7 1\n8 1\n9 1\n10 1\n11 1\n12 1\n13 1\n14 1\n15 1\n14\n1 1\n3 1\n4 1\n5 1\n6 1\n7 1\n8 1\n9 1\n10 1\n11 1\n12 1\n13 1\n14 1\n15 1\n14\n1 1\n2 1\n4 1\n5 1\n6 1\n7 1\n8 1\n9 1\n10 1\n11 1\n12 1\n13 1\n14 1\n15 1\n14\n1 1\n2 1\n3 1\n5 1\n6 1\n7 1\n8 1\n9... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have a string S consisting of... | [{"type": "stdin_stdout", "input": "99\nlbyhybgfptdyuqnlszvxoggbjhrjopbevyrzytfhiabtoozntnxxcvmhckjlwxnzniwzzxzvmfiztyirssfeauzncyosgrmsgull\n", "output": "lbyhybgfptdyuqnlszvxoggbjhrjopbevyrzytfhiabtoozntnxxcvmhckjlwxnzniwzzxzvmfiztyirssfeauzncyosgrmsgul...\n"}, {"type": "stdin_stdout", "input": "100\nvefcekrnrodmjprt... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nIn the Kingdom of AtCoder, peopl... | [{"type": "stdin_stdout", "input": "upruskhsmeicaqqesyyvopepmvdosibrvqoghdeikbpqbfgrufxdsqchjkuxpxngebxrmqdgqjsosencrbwknllvucvubyozfmttxtlsrrnrqavshaszrenhlbzpnpjgqftvwgukjwsekfcgllbzlnvmosmvqubtwsgltvmmzmslqdxqiifzkaqhsxzguseuexlycgubhdnwhrssyiybitcoowlhmmrdpgtrdwalvffknwibhwhacqfjcmwupoxonavvxwsvprpymskznabsquwssucx... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nN Snukes called Snuke 1, Snuke 2... | [{"type": "stdin_stdout", "input": "100 100\n100\n1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N slimes lining up fro... | [{"type": "stdin_stdout", "input": "99798\nbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nAs AtCoder Beginner Contest 100 ... | [{"type": "stdin_stdout", "input": "10000\n126382592 432418816 117063168 213396480 379143680 515038208 324231168 266539520 602792960 314653184 650153984 883734016 33309696 9005056 46451200 158759424 33279488 319342080 499438080 853167616 310094336 919876608 882363392 132034048 288561664 745817600 28561408 9703936 79297... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have A cards, each of which h... | [{"type": "stdin_stdout", "input": "206383196 349216559 1444400245 1999999999\n", "output": "-1238017048\n"}, {"type": "stdin_stdout", "input": "206383196 349216559 1444400245 2000000000\n", "output": "-1238017049\n"}, {"type": "stdin_stdout", "input": "1000000000 199342280 739321284 1199342280\n", "output": "100000000... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are some animals in a gard... | [{"type": "stdin_stdout", "input": "25 100\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "50 100\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "25 98\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "51 100\n", "output": "No\n"}, {"type": "stdin_stdout", "input": "32 96\n", "output": "Y... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given an undirected unwe... | [{"type": "stdin_stdout", "input": "8 28\n1 2\n1 3\n1 4\n1 5\n1 6\n1 7\n1 8\n2 3\n2 4\n2 5\n2 6\n2 7\n2 8\n3 4\n3 5\n3 6\n3 7\n3 8\n4 5\n4 6\n4 7\n4 8\n5 6\n5 7\n5 8\n6 7\n6 8\n7 8\n", "output": "5040\n"}, {"type": "stdin_stdout", "input": "8 27\n1 2\n1 3\n1 4\n1 5\n1 6\n1 7\n1 8\n2 3\n2 4\n2 5\n2 6\n2 7\n3 4\n3 5\n3 6... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nLet us define the FizzBuzz seque... | [{"type": "stdin_stdout", "input": "1000000\n", "output": "266666333332\n"}, {"type": "stdin_stdout", "input": "999997\n", "output": "266665333334\n"}, {"type": "stdin_stdout", "input": "870108\n", "output": "201890463153\n"}, {"type": "stdin_stdout", "input": "445802\n", "output": "52997595603\n"}, {"type": "stdin_std... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven are an integer X and an in... | [{"type": "stdin_stdout", "input": "51 100\n70 94 98 62 63 19 59 50 36 48 97 82 53 5 3 96 51 13 64 79 65 23 75 72 74 87 100 43 81 42 71 34 57 88 60 77 31 12 10 52 29 92 66 1 61 90 21 55 22 30 14 35 41 2 78 37 15 73 69 58 25 67 28 16 99 38 85 33 20 95 32 24 80 40 4 45 11 83 7 17 91 89 54 18 26 56 9 27 68 47 76 93 39 84 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are H rows and W columns o... | [{"type": "stdin_stdout", "input": "13 13\n8 10\n", "output": "15\n"}, {"type": "stdin_stdout", "input": "20 20\n19 19\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "19 19\n5 3\n", "output": "224\n"}, {"type": "stdin_stdout", "input": "20 20\n1 1\n", "output": "361\n"}, {"type": "stdin_stdout", "input": "20 2... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given a sequence of inte... | [{"type": "stdin_stdout", "input": "4 4\n1000000000 1000000000 1000000000 1000000000\n", "output": "1000000000\n"}, {"type": "stdin_stdout", "input": "2 2\n1000000000 1000000000\n", "output": "1000000000\n"}, {"type": "stdin_stdout", "input": "1 1\n1000000000\n", "output": "1000000000\n"}, {"type": "stdin_stdout", "inp... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA star is a figure of the follow... | [{"type": "stdin_stdout", "input": "100 3\n...\n...\n...\n...\n...\n...\n...\n*..\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n.*.\n***\n.*.\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n...\n..... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nLet's call (yet again) a string ... | [{"type": "stdin_stdout", "input": "100\nabbbbaabbbbababbbabababbbabaabaababaaababbbaaaabbabbbbbbbabbbbbbbbabbbaaababbaaabbabbaabaaabaaabbabb\n", "output": "38\nabbaabbababababababaabababababbaabbabababaababbaabbabaabababba\n"}, {"type": "stdin_stdout", "input": "33\njffufkhhlvdkeagezgwsoikbyqxzqwkvc\n", "output": "1\n... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given a connected undire... | [{"type": "stdin_stdout", "input": "10 10\n9 2\n6 4\n2 10\n7 8\n8 6\n9 3\n2 6\n7 1\n7 4\n5 4\n", "output": "YES\n0010101000\n"}, {"type": "stdin_stdout", "input": "10 10\n6 8\n9 10\n10 1\n2 10\n10 7\n3 1\n8 1\n2 1\n4 1\n5 10\n", "output": "NO\n"}, {"type": "stdin_stdout", "input": "10 10\n3 4\n3 5\n8 9\n5 1\n7 3\n3 2\n... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given four integers A, B... | [{"type": "stdin_stdout", "input": "123456789987654321 987654321123456789 999999999 1000000000\n", "output": "864197529407407405\n"}, {"type": "stdin_stdout", "input": "314159265358979323 846264338327950288 419716939 937510582\n", "output": "532105071133627368\n"}, {"type": "stdin_stdout", "input": "827191816666888190 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nAn integer N is a multiple of 9 ... | [{"type": "stdin_stdout", "input": "33813819154164361588118768953262516554574111032083043031384286303065210509562262038973079975476396016546146039303789823110933080134565927492314604458575884820133400398416950126075966048913496870281342656762187821939147033106717650124502612019109078419691362651717290499399798948652832... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTo make it difficult to withdraw... | [{"type": "stdin_stdout", "input": "44852\n", "output": "16\n"}, {"type": "stdin_stdout", "input": "43637\n", "output": "16\n"}, {"type": "stdin_stdout", "input": "99788\n", "output": "15\n"}, {"type": "stdin_stdout", "input": "35861\n", "output": "15\n"}, {"type": "stdin_stdout", "input": "100000\n", "output": "7\n"},... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given string S and T con... | [{"type": "stdin_stdout", "input": "pgykichjtpukfnlxfcevkjezqsmeycanjlbessrfazdprcomdpjimsfbuslksyveergcgmonctcsvypolplcgsqyfkilrixodiwq\nfnlxfcevkjezqsmeycanjlbessrfazdprcomdpjimsfbuslksyveergcgmonctcsvypolplcgsqyfkilrixodiwqpgykichjtpuk\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "aaaaaaaaaaaaaaaaaaaaaa... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven are two strings S and T.\n... | [{"type": "stdin_stdout", "input": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given positive integers ... | [{"type": "stdin_stdout", "input": "100 100 1\n", "output": "100\n"}, {"type": "stdin_stdout", "input": "100 50 4\n", "output": "5\n"}, {"type": "stdin_stdout", "input": "96 96 12\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "60 60 11\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "93 31 1\n", "outp... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi loves gold coins. He g... | [{"type": "stdin_stdout", "input": "1000000000\n", "output": "2000000000\n"}, {"type": "stdin_stdout", "input": "999999999\n", "output": "1999999495\n"}, {"type": "stdin_stdout", "input": "999999994\n", "output": "1999999490\n"}, {"type": "stdin_stdout", "input": "999999499\n", "output": "1999998495\n"}, {"type": "stdi... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N people living on a n... | [{"type": "stdin_stdout", "input": "100\n1 1 1 100 100 1 100 1 100 100 100 1 100 1 1 1 100 1 100 100 100 1 1 100 100 100 100 100 100 1 1 100 100 100 100 100 1 100 1 1 1 100 100 100 1 100 1 100 100 1 1 1 1 1 1 100 1 1 100 1 1 1 100 100 1 1 100 100 100 100 100 1 100 1 1 100 1 1 1 100 1 100 100 100 1 1 1 100 1 1 100 100 1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi's house has only one s... | [{"type": "stdin_stdout", "input": "13 17\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "10 19\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "20 19\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "2 20\n", "output": "19\n"}, {"type": "stdin_stdout", "input": "4 10\n", "output": "3\n"}, {"typ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\n-----Input-----\n\nThe first lin... | [{"type": "stdin_stdout", "input": "14\n99.19 -882.27\n468.09 310.41\n-539.17 665.55\n-355.65 -90.01\n490.35 -966.88\n-102.77 252.03\n981.63 -976.33\n-363.05 -435.09\n-44.93 -37.28\n947.69 530.68\n49.38 -299.65\n503.33 684.17\n199.13 328.89\n31.24 65.36\n", "output": "-55.744\n"}, {"type": "stdin_stdout", "input": "8\n... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThe only difference between easy... | [{"type": "stdin_stdout", "input": "100 10000\n93 99 95 105 94 108 104 104 102 112 106 82 114 104 88 107 105 104 93 96 103 109 105 82 107 95 83 93 120 115 96 104 96 86 87 102 103 108 97 84 108 117 109 107 80 87 102 107 88 97 96 101 101 114 106 103 99 101 105 102 85 94 98 101 115 100 91 92 108 105 94 110 91 89 119 119 9... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given an array $s$ consi... | [{"type": "stdin_stdout", "input": "36 17\n1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3\n", "output": "1 1 1 1 1 1 1 1 1 2 2 2 2 3 3 3 3 \n"}, {"type": "stdin_stdout", "input": "30 15\n1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2\n", "output": "1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 \n"... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given a matrix $a$, cons... | [{"type": "stdin_stdout", "input": "5 5\n1337 1337 1337 1337 1337\n1337 1337 1337 1337 1337\n1337 1337 1337 1337 1337\n1337 1337 1337 1337 1337\n1337 1337 1337 1337 1337\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "5 5\n420 420 420 420 420\n420 420 420 420 420\n420 420 420 420 420\n420 420 420 420 420\n420 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou can not just take the file a... | [{"type": "stdin_stdout", "input": "100\nxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n", "output": "98\n"}, {"type": "stdin_stdout", "input": "100\nuxxxxxlmexxxxxxxwnxxexxxxxcxxfydxxxxxxvmdxxxxxxisxxxxxxxxidkxxxpxxxxxxxxmnuxxxxjxxxqcxxwmxxxxxxxxmrx\n", "output": ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nIt is known that the area of a r... | [{"type": "stdin_stdout", "input": "100\n", "output": "30000\n"}, {"type": "stdin_stdout", "input": "80\n", "output": "19200\n"}, {"type": "stdin_stdout", "input": "66\n", "output": "13068\n"}, {"type": "stdin_stdout", "input": "93\n", "output": "25947\n"}, {"type": "stdin_stdout", "input": "98\n", "output": "28812\n"}... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are S sheep and W wolves.\... | [{"type": "stdin_stdout", "input": "100 100\n", "output": "unsafe\n"}, {"type": "stdin_stdout", "input": "10 10\n", "output": "unsafe\n"}, {"type": "stdin_stdout", "input": "99 99\n", "output": "unsafe\n"}, {"type": "stdin_stdout", "input": "74 74\n", "output": "unsafe\n"}, {"type": "stdin_stdout", "input": "63 64\n", ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere is a right triangle ABC wi... | [{"type": "stdin_stdout", "input": "28 96 100\n", "output": "1344\n"}, {"type": "stdin_stdout", "input": "35 84 91\n", "output": "1470\n"}, {"type": "stdin_stdout", "input": "77 36 85\n", "output": "1386\n"}, {"type": "stdin_stdout", "input": "45 28 53\n", "output": "630\n"}, {"type": "stdin_stdout", "input": "24 10 26... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi likes the sound when h... | [{"type": "stdin_stdout", "input": "100 100 100\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "1 100 100\n", "output": "100\n"}, {"type": "stdin_stdout", "input": "1 100 99\n", "output": "99\n"}, {"type": "stdin_stdout", "input": "100 1 10\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "4 99 23\n", "... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nCompute A \\times B.\n\n-----Con... | [{"type": "stdin_stdout", "input": "100 100\n", "output": "10000\n"}, {"type": "stdin_stdout", "input": "22 75\n", "output": "1650\n"}, {"type": "stdin_stdout", "input": "26 45\n", "output": "1170\n"}, {"type": "stdin_stdout", "input": "72 81\n", "output": "5832\n"}, {"type": "stdin_stdout", "input": "47 29\n", "output... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA biscuit making machine produce... | [{"type": "stdin_stdout", "input": "1 20 20\n", "output": "400\n"}, {"type": "stdin_stdout", "input": "20 20 19\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "7 10 12\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "8 16 20\n", "output": "32\n"}, {"type": "stdin_stdout", "input": "4 13 17\n", "output... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi the Jumbo will practic... | [{"type": "stdin_stdout", "input": "1000\n2 1000\n", "output": "OK\n"}, {"type": "stdin_stdout", "input": "279\n691 872\n", "output": "OK\n"}, {"type": "stdin_stdout", "input": "379\n400 757\n", "output": "NG\n"}, {"type": "stdin_stdout", "input": "1000\n1 999\n", "output": "NG\n"}, {"type": "stdin_stdout", "input": "1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nIn order to pass the entrance ex... | [{"type": "stdin_stdout", "input": "100 1\n", "output": "100.0000000000\n"}, {"type": "stdin_stdout", "input": "100 17\n", "output": "5.8823529412\n"}, {"type": "stdin_stdout", "input": "56 100\n", "output": "0.5600000000\n"}, {"type": "stdin_stdout", "input": "99 1\n", "output": "99.0000000000\n"}, {"type": "stdin_std... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have two bottles for holding ... | [{"type": "stdin_stdout", "input": "20 20 20\n", "output": "20\n"}, {"type": "stdin_stdout", "input": "10 1 20\n", "output": "11\n"}, {"type": "stdin_stdout", "input": "16 5 15\n", "output": "4\n"}, {"type": "stdin_stdout", "input": "20 1 19\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "19 5 13\n", "output":... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have two permutations P and Q... | [{"type": "stdin_stdout", "input": "8\n7 3 5 4 2 1 6 8\n3 8 2 5 4 6 7 1\n", "output": "17517\n"}, {"type": "stdin_stdout", "input": "8\n5 7 4 2 8 3 6 1\n1 7 8 4 6 2 5 3\n", "output": "19898\n"}, {"type": "stdin_stdout", "input": "8\n1 2 3 4 5 6 7 8\n8 7 6 5 4 3 2 1\n", "output": "40319\n"}, {"type": "stdin_stdout", "in... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given a string S consist... | [{"type": "stdin_stdout", "input": "TTTTTTTTTT\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "BBBBBBBBBB\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "GACGCTCCAV\n", "output": "9\n"}, {"type": "stdin_stdout", "input": "CTTAHTGACT\n", "output": "5\n"}, {"type": "stdin_stdout", "input": "TGMJCTTDAA\... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven is an integer N. Find the ... | [{"type": "stdin_stdout", "input": "100000\n", "output": "90909\n"}, {"type": "stdin_stdout", "input": "45901\n", "output": "36811\n"}, {"type": "stdin_stdout", "input": "99924\n", "output": "90834\n"}, {"type": "stdin_stdout", "input": "99999\n", "output": "90909\n"}, {"type": "stdin_stdout", "input": "10000\n", "outp... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven are strings S and T. Consi... | [{"type": "stdin_stdout", "input": "sjpvbzildfxlaukqtfznjjyryrdawsycubdpieejlzsexyhuajiqqigetwdyjeignkuuedzguvqhyrubpdfsenayqahbaqnyhavlaptlqtrotfzvbqbtpkuddnopjzoteuubxgkthzdyepesqgozkdvkcakraxeulhhqtnpolbtcsgxgskjjzdimcyhclnnwfbxwmznpvjaqjqqogwgwmzzpcvhywpcocmsxxmgsodckxvipzobspvwjezxugjlivdhefgdfkzzidktxjcnayjubmsqm... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou will turn on the air conditi... | [{"type": "stdin_stdout", "input": "30\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "40\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "-40\n", "output": "No\n"}, {"type": "stdin_stdout", "input": "-29\n", "output": "No\n"}, {"type": "stdin_stdout", "input": "-30\n", "output": "No\n"}, {"type": ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are N points in a D-dimens... | [{"type": "stdin_stdout", "input": "10 10\n8 -14 -14 -20 18 -1 -3 18 -1 10\n-9 2 4 -13 13 5 14 -9 20 -18\n-19 -19 -19 20 -3 20 -2 -18 -7 -11\n5 7 3 -11 12 -9 -10 10 20 -19\n-12 -8 -20 -13 12 13 17 17 -6 0\n-4 -14 -15 -15 18 19 -8 -1 -20 -2\n-7 11 -10 -16 3 -5 -12 15 6 -2\n12 18 -3 -15 -20 17 9 9 10 -10\n10 -2 9 -16 2 1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThe door of Snuke's laboratory i... | [{"type": "stdin_stdout", "input": "8080\n", "output": "Good\n"}, {"type": "stdin_stdout", "input": "0930\n", "output": "Good\n"}, {"type": "stdin_stdout", "input": "8901\n", "output": "Good\n"}, {"type": "stdin_stdout", "input": "3695\n", "output": "Good\n"}, {"type": "stdin_stdout", "input": "4649\n", "output": "Good... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou have a pot and N ingredients... | [{"type": "stdin_stdout", "input": "50\n1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000\n", "output": "1000\n"}, {"typ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi went to an all-you-can... | [{"type": "stdin_stdout", "input": "20\n1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20\n50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50\n50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50\n", "output": "1950\n"}, {"type": "stdin_stdout", "input": "20\n1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWe have a string S of length N c... | [{"type": "stdin_stdout", "input": "50\nABCABCABCABCABCABCABCABCABCABCABCABCABCABCABCABCAB\n", "output": "16\n"}, {"type": "stdin_stdout", "input": "50\nBMZBMWEYYDIADTLCOUEGMDBYFWURPWBPUVHIFNUAPWYNDMHTQV\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "50\nKGKBHTYTSZOTWFLEGSJZZSZFWTZFPNSCGUEMWRCZQXYCIVDQNK\n", ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTakahashi is participating in a ... | [{"type": "stdin_stdout", "input": "22 22\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "75 75\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "26 26\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "45 45\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "72 72\n", "output": "Yes... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA string of length 6 consisting ... | [{"type": "stdin_stdout", "input": "sippuu\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "coffee\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "dceett\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "otjjmm\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "zkrrcc\n", "output":... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nWhen Mr. X is away from home, he... | [{"type": "stdin_stdout", "input": "100 79\n359 483\n836 935\n246 178\n901 621\n246 967\n428 447\n65 252\n294 631\n903 95\n965 92\n901 614\n528 580\n420 398\n727 132\n266 536\n991 973\n419 606\n710 676\n418 666\n268 141\n500 874\n685 455\n868 169\n222 348\n748 482\n535 214\n487 952\n52 336\n380 985\n581 209\n516 292\n2... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nN of us are going on a trip, by ... | [{"type": "stdin_stdout", "input": "20 50 50\n", "output": "50\n"}, {"type": "stdin_stdout", "input": "10 4 41\n", "output": "40\n"}, {"type": "stdin_stdout", "input": "2 13 33\n", "output": "26\n"}, {"type": "stdin_stdout", "input": "18 3 19\n", "output": "19\n"}, {"type": "stdin_stdout", "input": "19 2 38\n", "output... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThe only difference between the ... | [{"type": "stdin_stdout", "input": "10\n1\n10\n100\n1000\n10000\n100000\n1000000\n10000000\n100000000\n1000000000\n", "output": "1\n4\n1\n4\n9\n2\n6\n2\n6\n8\n"}, {"type": "stdin_stdout", "input": "4\n2132\n506\n999999999\n1000000000\n", "output": "8\n2\n9\n8\n"}, {"type": "stdin_stdout", "input": "5\n1\n3\n20\n38\n56\... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nTreeland consists of $n$ cities ... | [{"type": "stdin_stdout", "input": "10 2\n10 3\n1 2\n1 3\n1 4\n2 5\n2 6\n2 7\n3 8\n3 9\n", "output": "3\n1 1 2 3 2 3 1 3 1 "}, {"type": "stdin_stdout", "input": "6 2\n1 4\n4 3\n3 5\n3 6\n5 2\n", "output": "2\n1 2 1 1 2 "}, {"type": "stdin_stdout", "input": "4 2\n3 1\n1 4\n1 2\n", "output": "1\n1 1 1 "}, {"type": "stdin... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nOh, New Year. The time to gather... | [{"type": "stdin_stdout", "input": "10\n10 7 10 10 7 10 7 7 10 10\n", "output": "2 6\n"}, {"type": "stdin_stdout", "input": "10\n1 2 3 4 5 6 7 8 9 10\n", "output": "4 10\n"}, {"type": "stdin_stdout", "input": "10\n6 6 6 6 6 6 6 6 6 6\n", "output": "1 3\n"}, {"type": "stdin_stdout", "input": "10\n6 8 9 6 5 9 4 8 8 6\n",... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nThere are $n$ kids, numbered fro... | [{"type": "stdin_stdout", "input": "8\n8 5\n8 1\n6 4\n2 6\n7 3\n2 1\n4 3\n7 5\n", "output": "5 7 3 4 6 2 1 8 \n"}, {"type": "stdin_stdout", "input": "7\n2 3\n6 3\n7 6\n5 1\n1 2\n7 4\n5 4\n", "output": "3 6 7 4 5 1 2 \n"}, {"type": "stdin_stdout", "input": "6\n2 4\n5 3\n1 6\n2 5\n3 6\n4 1\n", "output": "2 5 3 6 1 4 \n"}... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are a coach at your local un... | [{"type": "stdin_stdout", "input": "100\n1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337 1337... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nVova is playing a computer game.... | [{"type": "stdin_stdout", "input": "20\n1000000000 510000100 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 500000000 2 1\n1000000000 999999995 2 1\n1000000000 999999995... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nPolycarp lives on a coordinate l... | [{"type": "stdin_stdout", "input": "100 50 1\n1 2\n3 4\n5 6\n7 8\n9 10\n11 12\n13 14\n15 16\n17 18\n19 20\n21 22\n23 24\n25 26\n27 28\n29 30\n31 32\n33 34\n35 36\n37 38\n39 40\n41 42\n43 44\n45 46\n47 48\n49 50\n51 52\n53 54\n55 56\n57 58\n59 60\n61 62\n63 64\n65 66\n67 68\n69 70\n71 72\n73 74\n75 76\n77 78\n79 80\n81 ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA triple of numbers is said to b... | [{"type": "stdin_stdout", "input": "5 7 5\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "3 3 4\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "6 1 6\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "8 8 2\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "9 1 1\n", "output": "Yes... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA country decides to build a pal... | [{"type": "stdin_stdout", "input": "1000\n20 -20\n51765 34765 54644 24887 70030 45034 46376 88410 33772 52941 79750 44783 70874 36236 36651 16147 23251 11281 36605 69084 74679 18310 88655 92253 0 76064 82769 20419 60361 61197 51619 35110 6063 82815 99426 22379 61759 34008 31814 22642 80907 10203 11864 18291 34343 35250... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nYou are given a string S of leng... | [{"type": "stdin_stdout", "input": "8 3\nACACTACG\n3 7\n2 3\n1 8\n", "output": "2\n0\n3\n"}, {"type": "stdin_stdout", "input": "2 1\nAA\n1 2\n", "output": "0\n"}] | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nA shop sells N kinds of fruits, ... | [{"type": "stdin_stdout", "input": "1000 1000\n1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 100... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nX and A are integers between 0 a... | [{"type": "stdin_stdout", "input": "7 5\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "6 6\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "0 0\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "9 9\n", "output": "10\n"}, {"type": "stdin_stdout", "input": "1 1\n", "output": "10\n"}, {"type": ... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven any integer x, Aoki can do... | [{"type": "stdin_stdout", "input": "999999482938498888 1000000000000000000\n", "output": "517061501112\n"}, {"type": "stdin_stdout", "input": "34439284758432890 4389039281938432\n", "output": "673029497074566\n"}, {"type": "stdin_stdout", "input": "542309233112233445 542309233112233445\n", "output": "0\n"}, {"type": "s... | code_stdio |
[
{
"content": "You are an expert Python programmer. You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\nSolve the following coding problem using the programming language python:\n\nGiven are three integers A_1, A_... | [{"type": "stdin_stdout", "input": "13 13 13\n", "output": "bust\n"}, {"type": "stdin_stdout", "input": "1 10 11\n", "output": "bust\n"}, {"type": "stdin_stdout", "input": "6 13 10\n", "output": "bust\n"}, {"type": "stdin_stdout", "input": "13 7 2\n", "output": "bust\n"}, {"type": "stdin_stdout", "input": "11 6 5\n", "... | code_stdio |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.