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\nThe \"BerCorp\" company has got ... | [{"type": "stdin_stdout", "input": "100 100\n1 33\n0\n2 35 4\n2 40 78\n1 69\n0\n1 2\n0\n0\n2 81 34\n1 45\n0\n1 87\n1 50\n1 97\n0\n2 100 59\n0\n0\n0\n1 45\n0\n0\n0\n1 6\n1 54\n0\n0\n0\n4 79 96 52 84\n1 86\n0\n0\n0\n0\n0\n0\n0\n0\n3 90 2 80\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n1 2\n0\n1 64\n0\n1 78\n1 82\n0\n0\n0\n0\n0\n1 6\n0... | 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\nTheofanis decided to visit his u... | [{"type": "stdin_stdout", "input": "4\n1 1 1\n1 1 1\n100 50 200\n56220 47258 14497\n", "output": "YES\nYES\nNO\nYES\n"}, {"type": "stdin_stdout", "input": "4\n1 1 1\n1 -1 2\n110 50 200\n56220 47258 14497\n", "output": "YES\nNO\nNO\nYES\n"}, {"type": "stdin_stdout", "input": "4\n1 1 1\n1 -1 2\n110 53 200\n56220 47258 14... | 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 is an interactive problem. ... | [{"type": "stdin_stdout", "input": "10 120 15\n6\n11\n9\n11\n3\n12\n11\n12\n2\n8\n3\n11\n13\n5\n12\n18\n9\n3\n10\n9\n9\n13\n13\n5\n6\n11\n3\n15\n8\n8\n10\n13\n7\n6\n4\n14\n9\n10\n5\n13\n4\n1\n8\n6\n13\n1\n3\n4\n9\n12\n2\n7\n3\n3\n7\n2\n2\n9\n2\n4\n2\n2\n11\n12\n15\n13\n6\n2\n11\n1\n8\n3\n13\n6\n15\n6\n4\n3\n4\n15\n15\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\n### Background\n\nI was reading ... | [{"input": "\"123220\"\n10", "output": "[false]", "fn_name": "is_polydivisible"}, {"input": "\"30043052\"\n6", "output": "[true]", "fn_name": "is_polydivisible"}, {"input": "\"12345\"\n10", "output": "[false]", "fn_name": "is_polydivisible"}, {"input": "\"1234\"\n10", "output": "[false]", "fn_name": "is_polydivisible"}... | code_functional |
[
{
"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\nTwo-gram is an ordered pair (i.e... | [{"type": "stdin_stdout", "input": "100\nURXCAIZFIBNJTPCZHBQIBCILLPXZCFGMKKZMNPLCYGAVJVIBMCZEBSJWPSCPQDYCTTKPOKIJRSKIZPDGCHVOUTMPNECYORSFZFNC\n", "output": "IB\n"}, {"type": "stdin_stdout", "input": "100\nAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA\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\nIn the Ancient Kingdom of Snuke,... | [{"type": "stdin_stdout", "input": "100\n10 12 512917373\n6 9 512917366\n66 44 512917421\n49 18 512917412\n57 96 512917426\n65 72 512917442\n62 59 512917440\n27 77 512917437\n31 13 512917395\n38 39 512917428\n15 72 512917430\n0 69 512917418\n22 22 512917395\n9 69 512917427\n37 96 512917428\n12 23 512917386\n100 90 5129... | 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\nOne of the most important produc... | [{"type": "stdin_stdout", "input": "gerald.agapov1991@gmail.com\n", "output": " 18"}, {"type": "stdin_stdout", "input": "x@x.x@x.x_e_@r1.com\n", "output": " 8"}, {"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\nVanya has a scales for weighing ... | [{"type": "stdin_stdout", "input": "1000000000 1000000000\n", "output": "YES\n"}, {"type": "stdin_stdout", "input": "1000000000 1000000000\n", "output": "YES\n"}, {"type": "stdin_stdout", "input": "1100000000 1000000000\n", "output": "NO\n"}, {"type": "stdin_stdout", "input": "441890232 441890232\n", "output": "YES\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\nVasya has a sequence of cubes an... | [{"type": "stdin_stdout", "input": "10 1 10\n6 7 6 1 10 10 9 5 3 9\n7 10 9 6 1 5 9 3 10 6\n", "output": "TRUTH\n"}, {"type": "stdin_stdout", "input": "10 1 10\n6 7 6 1 10 10 9 5 3 9\n7 10 9 6 1 5 9 3 10 6\n", "output": "TRUTH\n"}, {"type": "stdin_stdout", "input": "8 3 6\n5 3 1 1 1 1 1 10\n3 3 1 1 1 1 5 5\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\nPrint the circumference of a cir... | [{"type": "stdin_stdout", "input": "100\n", "output": "628.31853071795865162130\n"}, {"type": "stdin_stdout", "input": "73\n", "output": "458.67252742410977361942\n"}, {"type": "stdin_stdout", "input": "20\n", "output": "125.66370614359172463992\n"}, {"type": "stdin_stdout", "input": "38\n", "output": "238.761041672824... | 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 user of a site th... | [{"type": "stdin_stdout", "input": "2002\n2017\n", "output": "2032\n"}, {"type": "stdin_stdout", "input": "4500\n-140", "output": "-4780\n"}, {"type": "stdin_stdout", "input": "4500\n-148", "output": "-4796\n"}, {"type": "stdin_stdout", "input": "4500\n-237", "output": "-4974\n"}, {"type": "stdin_stdout", "input": "200... | 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 frog is initially at position ... | [{"type": "stdin_stdout", "input": "997674659 11231 35496\n", "output": "497677363010575988\n"}, {"type": "stdin_stdout", "input": "881706694 5710 46369\n", "output": "388703347089502553\n"}, {"type": "stdin_stdout", "input": "952549276 31416 33000\n", "output": "1718466614644254\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\nThe Little Elephant from the Zoo... | [{"type": "stdin_stdout", "input": "3\n3\n011\n5\n10001\n7\n0000000", "output": "0\n1\n7\n"}, {"type": "stdin_stdout", "input": "3\n3\n010\n5\n10001\n7\n0010000", "output": "0\n1\n4\n"}, {"type": "stdin_stdout", "input": "3\n3\n010\n5\n10001\n7\n1010000", "output": "0\n1\n3\n"}, {"type": "stdin_stdout", "input": "3\n3\... | 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\nDon Drumphet lives in a nice nei... | [{"input": "\"Melania\"", "output": "[[\"Melania\", \"Me\"]]", "fn_name": "who_is_paying"}, {"input": "\"Melissa\"", "output": "[[\"Melissa\", \"Me\"]]", "fn_name": "who_is_paying"}, {"input": "\"Mexico\"", "output": "[[\"Mexico\", \"Me\"]]", "fn_name": "who_is_paying"}, {"input": "\"Me\"", "output": "[[\"Me\"]]", "fn_... | code_functional |
[
{
"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 $n$ ... | [{"type": "stdin_stdout", "input": "4\n2 3\n1 2\n2 1\n2 4\n", "output": "17\n"}, {"type": "stdin_stdout", "input": "4\n2 3\n1 2\n2 1\n0 4\n", "output": "21\n"}, {"type": "stdin_stdout", "input": "4\n3 3\n2 3\n2 1\n2 4\n", "output": "16\n"}, {"type": "stdin_stdout", "input": "4\n2 3\n4 2\n2 1\n4 4\n", "output": "19\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\nSherlock and Watson are playing ... | [{"type": "stdin_stdout", "input": "1000000000\nrsiufeylcjcvvyaxuknaxpjmelvugtuymftujsimekkallagxngxgplmdjhkedlsifpuaajfmthxhkgiaogghtukedwkikfspvpsxbxlvhlfrsnshwbqqwcwcbhkondglvylwywuhjbbeqtnpxfhwjgymqjbeoirkhdijddqogrsxoiponylwgkmwvndkvwxgcipflivucqusakhpkunqfcndpsoopourwmakuvfypasplafvvuodwehpwxemmbglpivmfclucemphrl... | 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 Smart Beaver from ABBYY love... | [{"type": "stdin_stdout", "input": "4\n-64322865 -60701256 -53458038 -42593211 -38971602 -31728384 -24485166 -17241948 -2755512 4487706 11730924 18974142 22595751 33460578 40703796 44325405\n", "output": "-39994920\n-60701256 -64322865 44325405 40703796\n-2755512 33460578 -53458038 -17241948\n18974142 -31728384 1173092... | 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\nYour classmates asked you to cop... | [{"input": "-5\n-5", "output": "[0]", "fn_name": "paperwork"}, {"input": "5\n5", "output": "[25]", "fn_name": "paperwork"}, {"input": "5\n-5", "output": "[0]", "fn_name": "paperwork"}, {"input": "-5\n5", "output": "[0]", "fn_name": "paperwork"}, {"input": "5\n0", "output": "[0]", "fn_name": "paperwork"}] | code_functional |
[
{
"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\nHow many licks does it take to g... | [{"input": "{\"dragons\": 100, \"evil wizards\": 110, \"trolls\": 50}", "output": "[\"It took 512 licks to get to the tootsie roll center of a tootsie pop. The toughest challenge was evil wizards.\"]", "fn_name": "total_licks"}, {"input": "{\"freezing temps\": 10, \"clear skies\": -2}", "output": "[\"It took 260 licks ... | code_functional |
[
{
"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 bracket sequen... | [{"type": "stdin_stdout", "input": "((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((\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\nVasya has recently learned to ty... | [{"type": "stdin_stdout", "input": "hyyhddqhxhekehkwfhlnlsihzefwchzerevcjtokefplholrbvxlltdlafjxrfhleglrvlolojoqaolagtbeyogxlbgfolllslli\n", "output": "YES\n"}, {"type": "stdin_stdout", "input": "jhfbndhyzdvhbvhmhmefqllujdflwdpjbehedlsqfdsqlyelwjtyloxwsvasrbqosblzbowlqjmyeilcvotdlaouxhdpoeloaovb\n", "output": "YES\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 has decided to decorate... | [{"type": "stdin_stdout", "input": "100\n25 100 32 34 25 99 19 99 84 52 20 83 34 12 59 89 51 86 5 63 57 2 61 23 48 27 90 28 29 65 31 73 40 79 89 29 18 86 49 14 48 84 100 17 65 79 37 71 52 47 98 100 40 20 71 94 90 53 41 54 47 2 40 36 35 63 14 66 35 11 2 97 23 90 26 88 17 79 2 59 12 22 14 61 78 15 7 62 7 38 43 94 43 12 7... | 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": "2 -777", "output": "1556\n"}, {"type": "stdin_stdout", "input": "2 -839", "output": "1680\n"}, {"type": "stdin_stdout", "input": "1 -839", "output": "1679\n"}, {"type": "stdin_stdout", "input": "100 100\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "181 21", "output": "139\... | 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": "6 113 -1", "output": "106\n"}, {"type": "stdin_stdout", "input": "6 228 -1", "output": "221\n"}, {"type": "stdin_stdout", "input": "2 228 -1", "output": "225\n"}, {"type": "stdin_stdout", "input": "2 396 -1", "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\nVladik had started reading a com... | [{"type": "stdin_stdout", "input": "20 20\n18 17 2 3 16 15 1 9 12 8 20 11 13 14 4 5 19 7 10 6\n13 15 15\n1 1 1\n2 2 2\n11 14 11\n10 11 10\n2 8 6\n12 18 16\n4 8 8\n2 2 2\n5 11 11\n4 18 9\n5 6 6\n3 20 12\n8 8 8\n6 16 11\n9 18 18\n8 18 17\n1 1 1\n2 6 5\n1 4 3\n", "output": "No\nYes\nYes\nNo\nYes\nYes\nNo\nNo\nYes\nYes\nNo... | 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## Objective\n\nGiven a number `... | [{"input": "9999999999999999999999999", "output": "[0]", "fn_name": "sxore"}, {"input": "1000000", "output": "[1000000]", "fn_name": "sxore"}, {"input": "1000001", "output": "[1]", "fn_name": "sxore"}, {"input": "50", "output": "[51]", "fn_name": "sxore"}, {"input": "0", "output": "[0]", "fn_name": "sxore"}, {"input": ... | code_functional |
[
{
"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\nConsider a table of size $n \\ti... | [{"type": "stdin_stdout", "input": "96 1\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nW\nB\nW\nW\nW\nW\... | 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\nFinish the solution so that it t... | [{"input": "1234567890", "output": "[\"1,234,567,890\"]", "fn_name": "group_by_commas"}, {"input": "123456789", "output": "[\"123,456,789\"]", "fn_name": "group_by_commas"}, {"input": "12345678", "output": "[\"12,345,678\"]", "fn_name": "group_by_commas"}, {"input": "1234567", "output": "[\"1,234,567\"]", "fn_name": "g... | code_functional |
[
{
"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\nIvan is a student at Berland Sta... | [{"type": "stdin_stdout", "input": "4 113 370\n01110100100010110100110000000011001111110000100111111001011001110111110111001011010110000110110010101010110001000\n01101001111110001010001100101100111100111001001001001101110101100110110110001110100010111011101011101110011110100\n0110011000100111101000001010110011110001111... | 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\nAfter the big birthday party, Ka... | [{"type": "stdin_stdout", "input": "727\nbaabbabbbababbbbaaaabaabbaabababaaababaaababbbbababbbbbbbbbbaaabaabbbbbbbbaaaabaabbaaabaabbabaa\nddcdcccccccdccdcdccdddcddcddcddddcdddcdcdccddcdddddccddcccdcdddcdcccdccccccdcdcdccccccdccccccdc\nfffeefeffeefeeeeffefffeeefffeefffefeefefeeeffefefefefefefffffffeeeeeffffeefeeeeffffee... | 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\nVasya is an administrator of a p... | [{"type": "stdin_stdout", "input": "2\n#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab\n#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\n", "output": "#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa... | 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\nPetya once wrote a sad love song... | [{"type": "stdin_stdout", "input": "13 7\nsonokhisumiwo\n1 5\n2 10\n7 10\n1 13\n1 8\n1 9\n3 6\n", "output": "74\n125\n62\n191\n110\n131\n48\n"}, {"type": "stdin_stdout", "input": "13 7\nowimusihkooos\n1 7\n2 10\n7 8\n2 13\n2 8\n2 4\n6 9\n", "output": "109\n128\n17\n177\n102\n45\n47\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\nYou are given an integer sequenc... | [{"type": "stdin_stdout", "input": "10\n-1 1 2 3 2 8 6 7 14 4", "output": "4\n"}, {"type": "stdin_stdout", "input": "10\n-1 2 1 5 8 2 8 4 20 0", "output": "4\n"}, {"type": "stdin_stdout", "input": "10\n-1 2 1 5 8 4 8 4 20 0", "output": "3\n"}, {"type": "stdin_stdout", "input": "10\n-1 2 1 5 8 4 8 4 17 0", "output": "3\... | 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 Berland capital is shaken wi... | [{"type": "stdin_stdout", "input": "99 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\nVasya takes part in the orientee... | [{"type": "stdin_stdout", "input": "97 -13\n-17 -11 -20 -16 -11 -18 -17 -14 -19 -13 -11 -19 -15 -17 -11 -20 -10 -19 -10 -18 -11 -14 -11 -15 -13 -13 -11 -18 -18 -18 -11 -14 -20 -19 -10 -17 -18 -19 -17 -11 -11 -11 -20 -19 -16 -15 -18 -15 -15 -20 -19 -20 -16 -13 -17 -11 -13 -18 -10 -13 -10 -14 -12 -17 -20 -10 -11 -19 -19 ... | 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\nBased on some criterion, Snuke d... | [{"type": "stdin_stdout", "input": "12 12", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "1 3\n", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "1 10", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "7 10", "output": "Yes\n"}, {"type": "stdin_stdout", "input": "7 12", "output": "Yes\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\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\nKuro is living in a country call... | [{"type": "stdin_stdout", "input": "70 42 32\n25 50\n51 7\n39 61\n1 33\n20 5\n1 70\n1 63\n42 35\n64 16\n1 11\n39 42\n20 54\n11 14\n57 44\n1 59\n55 40\n25 3\n31 18\n38 68\n57 23\n39 57\n28 10\n39 20\n42 26\n58 6\n20 56\n57 2\n13 21\n15 69\n39 64\n1 39\n62 53\n39 13\n1 41\n22 12\n13 30\n68 67\n20 31\n51 15\n57 32\n59 34\... | 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\nPaul is at the orchestra. The st... | [{"type": "stdin_stdout", "input": "10 10 10 1\n8 10\n2 9\n1 10\n3 1\n8 5\n10 1\n4 10\n10 2\n5 3\n9 3\n", "output": "1787\n"}, {"type": "stdin_stdout", "input": "10 10 10 1\n8 10\n2 9\n1 10\n3 1\n8 5\n10 1\n4 10\n10 2\n5 3\n9 3\n", "output": "1787\n"}, {"type": "stdin_stdout", "input": "10 10 10 1\n1 10\n10 8\n7 4\n7 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\nB: Nakajima, let's do that! --Ma... | [{"type": "stdin_stdout", "input": "5 1\n2 3", "output": "NAKAJIMA\n"}, {"type": "stdin_stdout", "input": "3 1\n1 0", "output": "NAKAJIMA\n"}, {"type": "stdin_stdout", "input": "2 1\n1 2", "output": "NAKAJIMA\n"}, {"type": "stdin_stdout", "input": "3 2\n1 0", "output": "NAKAJIMA\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\nYou will receive 3 points for so... | [{"type": "stdin_stdout", "input": "CCCTTCACCCGGATCCAAATCCCTTAGAAATAATCCCCGACGGCGTTGTATCACCTCTGCACTTGTTAGTAAGGTCAGGCGTCCATTACGGAAGAACGTA\n", "output": "19\n"}, {"type": "stdin_stdout", "input": "GCATTACATGGGGGGGTCCTACGAGCCCGGCATCCCGGAAACTAGCCGGTTAATTTGGTTTAAACCCTCCCACCCCGGATTGTAACCCCCCTCATTGGTT\n", "output": "17\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 programmer on the deve... | [{"type": "stdin_stdout", "input": "6\nW 0 2\nW 0 2\nD 0\nW 2 1\nR 3\nR 2\n1\nR 1000000000\n0", "output": "-1\n-1\n\n-1\n\n"}, {"type": "stdin_stdout", "input": "6\nW 0 3\nW 0 2\nD 0\nW 2 1\nR 4\nR 1\n1\nR 1000000000\n0", "output": "-1\n-1\n\n-1\n\n"}, {"type": "stdin_stdout", "input": "6\nW 0 2\nW 0 2\nD 0\nW 3 1\nR 3... | 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 number \"zero\" is called \"... | [{"type": "stdin_stdout", "input": "1000000000000000000 1000000000000\n", "output": "20833333333333332\n"}, {"type": "stdin_stdout", "input": "1000000000000000000 1000000000000\n", "output": "20833333333333332\n"}, {"type": "stdin_stdout", "input": "1000000000000000000 470184984576\n", "output": "33333333333333332\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\nSome number of chocolate pieces ... | [{"type": "stdin_stdout", "input": "5\n30 44\n26\n18\n81\n18\n6\n", "output": "56\n"}, {"type": "stdin_stdout", "input": "5\n30 44\n26\n18\n81\n18\n10", "output": "54\n"}, {"type": "stdin_stdout", "input": "5\n30 29\n26\n18\n81\n18\n10", "output": "39\n"}, {"type": "stdin_stdout", "input": "5\n30 29\n26\n18\n81\n18\n19... | 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: Information Search\n\nproblem... | [{"type": "stdin_stdout", "input": "4 4\n0 2 10 11\n1 2 4 14", "output": "1 7\n2\n0\n1\n2\n4\n10\n11\n14\n"}, {"type": "stdin_stdout", "input": "4 4\n1 2 5 12\n2 3 4 13", "output": "1 7\n2\n1\n2\n3\n4\n5\n12\n13\n"}, {"type": "stdin_stdout", "input": "4 4\n1 2 4 12\n2 3 4 13", "output": "2 6\n2\n4\n1\n2\n3\n4\n12\n13\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\nTavas is a strange creature. Usu... | [{"type": "stdin_stdout", "input": "173700 6\nbcabcbcbcbaaacaccaacaccaabacabaacbcacbbccaccbcacbabcaccccccaacacabbbbbacabbaaacbcbbaccaccabbbbaabbacacbabccaabcabbbcacaaccbabbcaaaaaabccbbcabcacbcbcabcbcbbaabacaaccccabacaaaccacaaabbacacabbcccacbaabcacacbbaaaccaccbaccccccbccaabcacaacabaccababacabcccbcbbacbabacbcbabacbbaccaa... | 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$ monsters standing ... | [{"type": "stdin_stdout", "input": "6 2 3 3\n7 10 50 12 1 8\n", "output": "5\n"}, {"type": "stdin_stdout", "input": "6 2 3 2\n7 10 50 12 1 8\n", "output": "4\n"}, {"type": "stdin_stdout", "input": "6 2 3 2\n5 10 50 12 1 8\n", "output": "3\n"}, {"type": "stdin_stdout", "input": "6 2 2 2\n5 10 50 12 1 8\n", "output": "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\nDigits Are Not Just Characters\n... | [{"type": "stdin_stdout", "input": "2\nfile10\nfi2el0\nfile3", "output": "-\n-\n"}, {"type": "stdin_stdout", "input": "2\nfjle10\nfi2el0\niele3", "output": "-\n+\n"}, {"type": "stdin_stdout", "input": "2\n01eljf\nfi2el0\niele3", "output": "+\n+\n"}, {"type": "stdin_stdout", "input": "2\nflje10\nif3el0\n2elei", "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\nThis is a harder version of the ... | [{"type": "stdin_stdout", "input": "100\n4845 2410 1317 394 2977 1455 2708 1271 2918 1866 4125 534 4055 1726 1819 790 2526 836 4853 4057 1995 3178 2972 3487 3259 4324 3807 895 2308 1513 3213 3480 1131 2807 1343 3231 1277 2683 1559 825 3667 102 1491 2066 4607 1645 3421 1475 3073 2945 3933 1157 378 3238 4123 2901 2840 48... | 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```if-not:swift\nWrite simple .c... | [{"input": "\"camel case method\"", "output": "[\"CamelCaseMethod\"]", "fn_name": "camel_case"}, {"input": "\" camel case word\"", "output": "[\"CamelCaseWord\"]", "fn_name": "camel_case"}, {"input": "\"say hello \"", "output": "[\"SayHello\"]", "fn_name": "camel_case"}, {"input": "\"test case\"", "output": "[\"TestCas... | code_functional |
[
{
"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$ consi... | [{"type": "stdin_stdout", "input": "4\n4\n11 13 11 11\n5\n1 4 4 4 4\n10\n3 3 3 3 10 3 3 3 3 3\n3\n20 20 10\n", "output": "\n2\n1\n5\n3\n"}, {"type": "stdin_stdout", "input": "4\n4\n11 13 11 11\n5\n1 4 4 4 4\n10\n3 3 3 3 10 3 3 3 3 3\n3\n20 20 10\n", "output": "2\n1\n5\n3\n"}, {"type": "stdin_stdout", "input": "4\n4\n11... | 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\nFennec is fighting with N monste... | [{"type": "stdin_stdout", "input": "3 0\n1000000000 1000000000 1000000000\n", "output": "3000000000\n"}, {"type": "stdin_stdout", "input": "3 0\n1000000000 1000000000 1010000000", "output": "3010000000\n"}, {"type": "stdin_stdout", "input": "3 0\n1000000000 1000000000 1110000000", "output": "3110000000\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\nMomiji has got a rooted tree, co... | [{"type": "stdin_stdout", "input": "10\n1 2\n2 3\n3 4\n1 5\n2 6\n6 7\n4 8\n6 9\n9 10\n", "output": "3.81666666666666690000\n"}, {"type": "stdin_stdout", "input": "10\n1 2\n2 3\n3 4\n1 5\n2 6\n6 7\n7 8\n6 9\n9 10\n", "output": "3.8166666666666664\n"}, {"type": "stdin_stdout", "input": "10\n1 2\n2 3\n3 4\n1 5\n2 6\n8 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\nVasya is sitting on an extremely... | [{"type": "stdin_stdout", "input": "200 100\n56988719755815575893282254081467698462485803782142631369385180999746639622554559884281193367342283559238834106917388166048020056852911293394377949964185368886333934084399980368238188117302968424219707\n", "output": "295455656\n"}, {"type": "stdin_stdout", "input": "200 99\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\nThe Free Meteor Association (FMA... | [{"type": "stdin_stdout", "input": "6 5 30\n536048 34640 572197 62457 304174\n194764 325606 270468 784237 551632\n10580 294606 63164 543647 531895\n430397 576813 678878 323394 603231\n534567 804015 403517 886087 981939\n518845 962097 609792 877955 88610\nc 1 5\nc 2 5\nc 2 5\nr 5 3\nc 5 2\nc 4 5\nr 6 5\nc 2 1\nr 3 4\nr ... | 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 be some string consisting ... | [{"type": "stdin_stdout", "input": "99985 45273\n", "output": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000... | 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\nLeonardo Fibonacci in a rare por... | [{"input": "[3, 5, 2]\n[0, 1, 2]\n4", "output": "[17]", "fn_name": "custom_fib"}, {"input": "[7, 3, 4, 1]\n[1, 1]\n6", "output": "[2]", "fn_name": "custom_fib"}, {"input": "[1, 1]\n[0, 1]\n2", "output": "[2]", "fn_name": "custom_fib"}, {"input": "[1, 1]\n[0, 1]\n3", "output": "[3]", "fn_name": "custom_fib"}, {"input": ... | code_functional |
[
{
"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\"QAQ\" is a word to denote an e... | [{"type": "stdin_stdout", "input": "QCQAQAGAWAQQQAQAVQAQQQQAQAQQQAQAAATQAAVAAAQQQQAAAUUQAQQNQQWQQWAQAAQQKQYAQAAQQQAAQRAQQQWBQQQQAPBAQGQA\n", "output": "13174\n"}, {"type": "stdin_stdout", "input": "QQAQQAKQFAQLQAAWAMQAZQAJQAAQQOACQQAAAYANAQAQQAQAAQQAOBQQJQAQAQAQQQAAAAABQQQAVNZAQQQQAMQQAFAAEAQAQHQT\n", "output": "10420\... | 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\nPolandBall is a young, clever Ba... | [{"type": "stdin_stdout", "input": "1447\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "1127\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "1722\n", "output": "2\n"}, {"type": "stdin_stdout", "input": "1332\n", "output": "1\n"}, {"type": "stdin_stdout", "input": "1261\n", "output": "1\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 nth triangular number is def... | [{"type": "stdin_stdout", "input": "40\n14\n10\n55\n120\n199\n61\n150\n0", "output": "2 6\n2 14\n1 10\n2 21\n1 18\n4 29\n3 27\n3 14\n"}, {"type": "stdin_stdout", "input": "40\n14\n10\n55\n120\n269\n61\n150\n0", "output": "2 6\n2 14\n1 10\n2 21\n1 18\n3 31\n3 27\n3 14\n"}, {"type": "stdin_stdout", "input": "40\n14\n10\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\nVova is again playing some compu... | [{"type": "stdin_stdout", "input": "1 1 100\n100 99\n", "output": "9901\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nHEAL\nH... | 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$n$ fishermen have just returned... | [{"type": "stdin_stdout", "input": "10\n319645572 758298525 812547177 459359946 355467212 304450522 807957797 916787906 239781206 242840396\n", "output": "0\n"}, {"type": "stdin_stdout", "input": "10\n319645572 758298525 812547177 459359946 355467212 304450522 807957797 916787906 239781206 242840396\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 has three sisters: Alic... | [{"type": "stdin_stdout", "input": "5\n5 3 2 8\n100 101 102 105\n3 2 1 100000000\n10 20 15 14\n101 101 101 3\n", "output": "YES\nYES\nNO\nNO\nYES\n"}, {"type": "stdin_stdout", "input": "5\n5 3 2 8\n100 101 102 105\n3 2 1 100000000\n23 20 15 14\n011 101 101 3\n", "output": "YES\nYES\nNO\nYES\nNO\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\nYou are playing a computer game,... | [{"type": "stdin_stdout", "input": "53 1 27 3\n44 28 48 60 29 42 59 32 9 58 3 11 7 53 4 19 37 41 36 52 29 9 24 8 31 39 52 41 37 44 26 37 37 48 6 21 20 42 25 3 33 2 35 39 33 23 10 60 48 4 1 28 21\n1 1 11\n1 1 21\n1 1 3\n1 1 42\n1 1 16\n1 1 32\n1 1 52\n1 1 17\n1 1 39\n1 1 22\n1 1 31\n1 1 50\n1 1 23\n1 1 14\n1 1 41\n1 1 5... | 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$ dormitories in Ber... | [{"type": "stdin_stdout", "input": "3 10\n1010000000 1000000000 1000000000\n330201655 567869543 1000000000 1000000001 1500000000 1999999999 2000000000 2000000001 2754432345 3000000000\n", "output": "1 330201655\n1 567869543\n1 1000000000\n1 1000000001\n2 490000000\n2 989999999\n2 990000000\n2 990000001\n3 744432345\n3 ... | 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 night wasn't easy on Vasya.... | [{"type": "stdin_stdout", "input": "987654320023456789\n", "output": "29340299842560\n"}, {"type": "stdin_stdout", "input": "987654321123456789\n", "output": "33007837322880\n"}, {"type": "stdin_stdout", "input": "987654321123456780\n", "output": "55657759288320\n"}, {"type": "stdin_stdout", "input": "23490681737975942... | 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 time around, Baby Ehab will... | [{"type": "stdin_stdout", "input": "2 200\n", "output": "1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 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\nKenkoooo is planning a trip in R... | [{"type": "stdin_stdout", "input": "8 12 5 5\n2 8 685087149 1569714306\n6 1 298270585 209942236\n2 4 346080035 234079976\n1 5 131857300 40131411\n1 8 30723332 173476334\n2 6 447829832 706415811\n1 4 181424400 548830121\n4 4 30593148 195056405\n7 8 211146752 588024753\n1 6 127300821 203530153\n3 1 336869679 115858230\n4... | 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\nGhosts live in harmony and peace... | [{"type": "stdin_stdout", "input": "10 7 -626288749\n795312099 49439844 266151109\n-1357052512 23740808 624973405\n-513221420 -44452680 -391096559\n-350963348 -5068756 -160670209\n690883790 11897718 3356227\n-509035268 -76541374 -210137445\n-121282138 -32581578 230716703\n491731655 9500548 -13423963\n-665038289 4817024... | 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\"Balloons should be captured ef... | [{"type": "stdin_stdout", "input": "2\n10 100\n100 270\n2\n12 100\n100 280\n3\n100 150\n10 360\n40 450\n3\n100 150\n17 360\n40 440\n2\n100 10\n50 200\n2\n100 100\n50 110\n1\n15 10\n4\n1 10\n2 20\n3 100\n90 200\n0", "output": "OK 220\nOK 200\nOK 260\nOK 246\nNG 1\nNG 2\nNG 1\nOK 188\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\nAlica and Bob are playing a game... | [{"type": "stdin_stdout", "input": "1\n111111111111111110000000000000000\n", "output": "NET\n"}, {"type": "stdin_stdout", "input": "1\n111111111111111110000000000000000\n", "output": "NET\n"}, {"type": "stdin_stdout", "input": "1\n111111111111101110000000000000000\n", "output": "NET\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\nIntroduction to Disjunctions\nIn... | [{"input": "[false, true, true, true]\ntrue", "output": "[true]", "fn_name": "disjunction"}, {"input": "[true, true, true, true]\nfalse", "output": "[true]", "fn_name": "disjunction"}, {"input": "[false, true, false]\nfalse", "output": "[true]", "fn_name": "disjunction"}, {"input": "[false, true, true]\nfalse", "output... | code_functional |
[
{
"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\nproblem\n\nTo the west of the Au... | [{"type": "stdin_stdout", "input": "3 2\n26 58 0 50 135 000\n10 24 20 127 126 60\n40 60 20 90 90 131", "output": "60000\n"}, {"type": "stdin_stdout", "input": "1 1\n20 50 -2 50 70 000\n10 102 11 39 90 40\n75 100 36 102 159 8", "output": "1200\n"}, {"type": "stdin_stdout", "input": "1 1\n20 50 -3 50 70 000\n10 102 11 39... | 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\nToad Ivan has $m$ pairs of integ... | [{"type": "stdin_stdout", "input": "10 10\n1 3\n1 3\n1 3\n1 3\n1 3\n2 3\n1 5\n2 6\n2 7\n2 9\n", "output": "YES\n"}, {"type": "stdin_stdout", "input": "10 10\n1 3\n1 3\n1 3\n1 3\n1 3\n2 3\n1 5\n2 7\n2 7\n2 9\n", "output": "YES\n"}, {"type": "stdin_stdout", "input": "10 10\n1 3\n1 3\n1 3\n1 3\n1 3\n2 3\n1 5\n2 3\n2 7\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\nYou are given $n$ strings. Each ... | [{"type": "stdin_stdout", "input": "5\na\naba\nabacaba\nba\naba\n", "output": "YES\na\nba\naba\naba\nabacaba\n"}, {"type": "stdin_stdout", "input": "3\nqwerty\nqwerty\nqwerty\n", "output": "YES\nqwerty\nqwerty\nqwerty\n"}, {"type": "stdin_stdout", "input": "3\nqwerty\nqwerty\nqwerty\n", "output": "YES\nqwerty\nqwerty\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\nIt is Professor R's last class o... | [{"type": "stdin_stdout", "input": "70 11 17929\n10313 427 268935 211 197219 148 357 179290 97 358580 475 343 175 221 286864 429 304793 179290 189 363 221 340651 376509 453 251006 141 304793 358580 235 107574 141 358580 167 181 101469 335 286864 171 107574 105 449 358580 286864 161 286864 349 89645 197219 395 358580 23... | 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\nMishka wants to buy some food in... | [{"type": "stdin_stdout", "input": "6\n1\n10\n19\n9876\n12345\n1000000000\n", "output": "1\n11\n21\n10973\n13716\n1111111111\n"}, {"type": "stdin_stdout", "input": "6\n1\n10\n33\n9876\n12345\n1000000000\n", "output": "1\n11\n36\n10973\n13716\n1111111111\n"}, {"type": "stdin_stdout", "input": "6\n1\n10\n24\n9876\n12345\... | 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 water tanks in a row... | [{"type": "stdin_stdout", "input": "65\n1000000 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 16 19 20 21 22 23 44 25 26 35 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 104 59 60 61 62 63 64\n", "output": "15417.723076923077\n15417.723076923077\n15417.723076923077\n15417.7230769... | 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 a lowercase Latin characte... | [{"type": "stdin_stdout", "input": "26\nq\na\nz\nw\ns\nx\ne\nd\nc\nr\nf\nv\nt\ng\nb\ny\nh\nn\nu\nj\nm\ni\nk\no\nl\np\n", "output": "NO\nNO\nNO\nNO\nYES\nNO\nYES\nYES\nYES\nYES\nYES\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nNO\nYES\nNO\nNO\n"}, {"type": "stdin_stdout", "input": "10\na\nb\nc\nd\ne\nf\ng\nh\ni\nj\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 Bitlandians are quite weird ... | [{"type": "stdin_stdout", "input": "10\n2 658\n5 29\n2 558\n1 1275\n2 1177\n1 1033\n1 247\n-1 4605\n0 1170\n-1 999\n", "output": "AAAAAAAAAA\n"}, {"type": "stdin_stdout", "input": "10\n2 658\n5 66\n2 784\n1 1275\n2 1177\n1 999\n1 247\n-1 4605\n0 1170\n-1 999\n", "output": "AAAAAAAAAA\n"}, {"type": "stdin_stdout", "inpu... | 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# Task\n\nYour task is to write ... | [{"input": "[9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9, 1, 9]", "output": "[190]", "fn_name": "bowling_score"}, {"input": "[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 1, 0]", "output": "[11]", "fn_name": "bowling_score"}, {"input": "[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ... | code_functional |
[
{
"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# Story\n\nDue to lack of mainte... | [{"input": "360", "output": "[\"12:00\"]", "fn_name": "what_time_is_it"}, {"input": "180", "output": "[\"06:00\"]", "fn_name": "what_time_is_it"}, {"input": "270", "output": "[\"09:00\"]", "fn_name": "what_time_is_it"}, {"input": "90", "output": "[\"03:00\"]", "fn_name": "what_time_is_it"}, {"input": "30", "output": "[... | code_functional |
[
{
"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 permutation $p_1... | [{"type": "stdin_stdout", "input": "3\n4\n2 1 4 3\n6\n4 12 1 2 5 3\n5\n5 7 1 2 4\n", "output": "YES\n2 3 4\nYES\n1 2 3\nYES\n1 2 3\n"}, {"type": "stdin_stdout", "input": "3\n4\n2 1 4 3\n6\n4 12 1 2 5 3\n5\n5 8 1 2 4\n", "output": "YES\n2 3 4\nYES\n1 2 3\nYES\n1 2 3\n"}, {"type": "stdin_stdout", "input": "3\n4\n2 1 4 3\... | 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 balls placed in a ro... | [{"type": "stdin_stdout", "input": "-10 -2", "output": "1.1290058539e-05\n"}, {"type": "stdin_stdout", "input": "-3 -6", "output": "-0.00249895876718\n"}, {"type": "stdin_stdout", "input": "-3 -2", "output": "-0.0246913580247\n"}, {"type": "stdin_stdout", "input": "-5 9", "output": "3.43322753906e-05\n"}, {"type": "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\nWrite a function that rearranges... | [{"input": "700000000001", "output": "[710000000000]", "fn_name": "super_size"}, {"input": "123456789", "output": "[987654321]", "fn_name": "super_size"}, {"input": "608719", "output": "[987610]", "fn_name": "super_size"}, {"input": "666666", "output": "[666666]", "fn_name": "super_size"}, {"input": "2017", "output": "... | code_functional |
[
{
"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\nHint\n\n* One grid may be filled... | [{"type": "stdin_stdout", "input": "23\n1 1 3 1\n3 1 3 3\n3 3 1 3\n1 3 1 5\n1 5 3 5\n5 2 7 2\n7 2 7 4\n7 4 5 4\n5 4 5 6\n5 6 7 6\n11 4 13 4\n13 0 15 0\n15 0 15 4\n18 2 18 2\n21 5 23 5\n21 5 21 7\n21 7 23 7\n23 7 23 8\n23 9 21 9\n24 0 26 0\n24 0 24 4\n24 4 26 4\n26 0 26 4", "output": "-328\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\nThere are N towers in the town w... | [{"type": "stdin_stdout", "input": "7\n0 1\n0 2\n2 3\n0 4\n0 5\n0 6", "output": "2071\n"}, {"type": "stdin_stdout", "input": "7\n0 1\n0 2\n1 3\n0 4\n1 5\n0 6", "output": "1303\n"}, {"type": "stdin_stdout", "input": "7\n0 1\n0 2\n0 3\n0 4\n0 5\n0 6", "output": "4683\n"}, {"type": "stdin_stdout", "input": "7\n0 1\n0 2\n0... | 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$n$ students are taking an exam.... | [{"type": "stdin_stdout", "input": "27\n1 1\n0\n1 2\n0\n1 5\n0\n1 10\n0\n1 50\n0\n1 100\n0\n1 500\n0\n1 1000\n0\n1 5000\n0\n1 10000\n0\n1 50000\n0\n1 100000\n0\n1 5\n4\n1 5\n5\n1 10\n9\n1 10\n10\n1 100000\n9999\n1 100000\n100000\n1 4999\n386\n1 100000\n1\n4 5\n1 0 0 0\n4 5\n0 1 0 0\n4 5\n0 0 0 0\n4 5\n5 5 5 5\n4 5\n4 4... | 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 an award-winning garden... | [{"input": "100", "output": "[\"Your plant has had more than enough water for today!\"]", "fn_name": "rain_amount"}, {"input": "40", "output": "[\"Your plant has had more than enough water for today!\"]", "fn_name": "rain_amount"}, {"input": "39", "output": "[\"You need to give your plant 1mm of water\"]", "fn_name": "... | code_functional |
[
{
"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": "4000\nGBRBRGGRRBRGBBGGRRGBRGGBRGGGBBGRGBRBRGGBGGGGRRGGBGGRGGGGRRGGRRGBBBGGRBGRRBBGGBRRBGGGGGBGGBGGRBBBGBGRGGRBGGRGRRRBRGBBBGGGRRBGRBBGGRGGRGRBGRRBGGRBRGGBBRGBRGRRGGRBGBRGBRGRRBGBRRBGRGBBGBRBGBBRBBGBBGBGGRBBRGRRGGRRBBBBRBBGBBGGRGRBBGGGBGGGGRRBBRGBBBBBRGGGBGGBBBRGRGRBGGGGBGBRGGBRGBRRRB... | 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\nIgor K. always used to trust his... | [{"type": "stdin_stdout", "input": "10110010010001110110110111100100011101101110010100100010110101011001011101111001\n1001000100\n1011001001\n0101100101\n0001110110\n1000101101\n0110110000\n0000010011\n1101111001\n1101010111\n1110010100\n", "output": "13739427\n"}, {"type": "stdin_stdout", "input": "0001010110111011010... | 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 a consi... | [{"type": "stdin_stdout", "input": "100\n-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 -100 -100 -100 -100 -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\nThere are n students living in t... | [{"type": "stdin_stdout", "input": "50 50\n50 48 38 45 50 48 38 48 49 49 50 50 49 50 38 48 45 40 43 49 48 43 50 50 50 42 47 50 49 34 48 47 48 50 50 50 49 47 48 49 48 48 50 39 45 47 48 47 45 50\n", "output": "1.000000000000001\n"}, {"type": "stdin_stdout", "input": "50 50\n50 50 50 50 50 50 50 50 50 50 50 50 50 50 50 50... | 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\nDo the following for a four-digi... | [{"type": "stdin_stdout", "input": "6174\n3985\n3333\n0000", "output": "0\n3\nNA\n"}, {"type": "stdin_stdout", "input": "6174\n1779\n3333\n0000", "output": "0\n6\nNA\n"}, {"type": "stdin_stdout", "input": "6174\n1794\n3333\n0000", "output": "0\n5\nNA\n"}, {"type": "stdin_stdout", "input": "6174\n1542\n3333\n0000", "out... | 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\nGena loves sequences of numbers.... | [{"type": "stdin_stdout", "input": "73\n531 626 701 57 708 511 54 441 297 697 411 253 397 652 21 59 851 561 539 461 629 894 275 417 127 960 433 243 963 247 5 368 969 541 408 485 319 117 441 131 265 357 1 659 267 983 643 285 913 782 813 569 99 781 297 636 645 341 6 17 601 129 509 197 226 105 241 737 86 128 762 647 849\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 T9 typing predictor helps wi... | [{"input": "[\"gone\", \"hood\", \"good\", \"old\"]\n\"4663\"", "output": "[[\"gone\", \"hood\", \"good\"]]", "fn_name": "T9"}, {"input": "[\"goNe\", \"hood\", \"GOOD\", \"old\"]\n\"4663\"", "output": "[[\"goNe\", \"hood\", \"GOOD\"]]", "fn_name": "T9"}, {"input": "[\"good\", \"home\", \"new\"]\n\"4663\"", "output": "[... | code_functional |
[
{
"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\nIlya is working for the company ... | [{"type": "stdin_stdout", "input": "129341234876124184 1 2\n1 3 3\n1 1 2\n1 2 3\n3 1 1\n3 1 3\n3 2 3\n", "output": "64670617438062091 64670617438062093\n"}, {"type": "stdin_stdout", "input": "129341234876124184 1 2\n1 3 3\n1 1 2\n1 2 3\n3 1 1\n3 1 3\n3 2 3\n", "output": "64670617438062091 64670617438062093\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 map of Bertown can be repres... | [{"type": "stdin_stdout", "input": "20 50\n20 3\n5 16\n1 3\n10 11\n10 15\n15 9\n20 9\n14 6\n16 5\n13 4\n11 5\n3 20\n13 17\n11 8\n11 6\n12 14\n16 18\n17 13\n18 7\n3 1\n8 10\n17 15\n7 2\n9 13\n5 11\n6 1\n2 16\n8 18\n10 8\n4 13\n9 15\n14 12\n1 6\n9 20\n7 18\n6 14\n7 6\n18 16\n2 7\n3 11\n15 17\n3 12\n14 10\n4 14\n19 4\n11 ... | 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": "53937807463", "output": "10\n"}, {"type": "stdin_stdout", "input": "9876543210\n", "output": "6\n"}, {"type": "stdin_stdout", "input": "6983776800... | 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 International System of U... | [{"type": "stdin_stdout", "input": "7\n12.729479136172973 kilo metfrt\n0.45 mega sttaw\n0.000000000000000000000001 yotta mrags\n1000000000000000000000000 yocto seconds\n42 amperes\n0.951642419825234 joulfs\n1234.56789012345678901234567890 hecto pascals", "output": "1.2729479136172973 * 10^4 metfrt\n4.5 * 10^5 sttaw\n1 ... | code_stdio |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.