data_source stringclasses 1
value | prompt listlengths 2 2 | ability stringclasses 1
value | reward_model dict | extra_info dict |
|---|---|---|---|---|
primeintellect | [
{
"content": "You are a helpful assistant.",
"role": "system"
},
{
"content": "Solve the following coding problem using the programming language python:\n\nThe stardate is 1977 and the science and art of detecting Death Stars is in its infancy. Princess Heidi has received information about the stars... | code | {
"ground_truth": [
{
"input": "4\nXOOO\nXXOO\nOOOO\nXXXX\nXOOO\nXOOO\nXOXO\nXOXX\n",
"metadata": {
"func_name": null
},
"output": "Yes\n",
"testtype": "stdin"
},
{
"input": "2\nXX\nOO\nXO\nOX\n",
"metadata": {
"func_name": null
},
"out... | {
"index": 0,
"solution": "```python\nn=int(input())\na=[]\nb=[]\nfor i in range(n):\n a.append(input())\nfor i in range(n):\n b.append(input())\n\ndef h(d):\n c=[]\n for i in range(n):\n c.append(d[n-i-1])\n return c\ndef r(d):\n c=[]\n for i in range(n):\n temp=\"\"\n for... |
primeintellect | [
{
"content": "You are a helpful assistant.",
"role": "system"
},
{
"content": "Solve the following coding problem using the programming language python:\n\nThere is a kangaroo at coordinate 0 on an infinite number line that runs from left to right, at time 0. During the period between time i-1 and t... | code | {
"ground_truth": [
{
"input": "6",
"metadata": {
"func_name": null
},
"output": "3",
"testtype": "stdin"
},
{
"input": "11",
"metadata": {
"func_name": null
},
"output": "5",
"testtype": "stdin"
},
{
"input": "2",
... | {
"index": 1,
"solution": "```python\nimport math\nX = int(input())\nlow_N = (-1 + (1 + 8 * X)**0.5) / 2\nhigh_N = (1 + (1 + 8 * X)**0.5) / 2\nif low_N % 1 == 0:\n print(int(low_N))\nelse:\n print(math.floor(high_N))\n```",
"split": "train"
} |
primeintellect | [
{
"content": "You are a helpful assistant.",
"role": "system"
},
{
"content": "Solve the following coding problem using the programming language python:\n\nAndrewid the Android is a galaxy-famous detective. He is now investigating the case of vandalism at the exhibition of contemporary art.\n\nThe m... | code | {
"ground_truth": [
{
"input": "3 2\n2 1 2\n1 3\n",
"metadata": {
"func_name": null
},
"output": "1",
"testtype": "stdin"
},
{
"input": "7 3\n3 1 3 7\n2 2 5\n2 4 6\n",
"metadata": {
"func_name": null
},
"output": "10",
"testtype":... | {
"index": 2,
"solution": "```python\nn,k = map(int,input().split(\" \"))\ni=0\nres=k\nsh=0\nwhile i<k:\n i+=1\n mas=list(map(int,input().split(\" \")))[1:]\n\n\n if mas[0]==1:\n j=0\n while j<(len(mas)-1):\n\n if(mas[j]+1!=mas[j+1]):\n break\n else:\... |
primeintellect | [
{
"content": "You are a helpful assistant.",
"role": "system"
},
{
"content": "Solve the following coding problem using the programming language python:\n\nA car number in Berland consists of exactly n digits. A number is called beautiful if it has at least k equal digits. Vasya wants to change the ... | code | {
"ground_truth": [
{
"input": "3 2\n533\n",
"metadata": {
"func_name": null
},
"output": "0\n533\n",
"testtype": "stdin"
},
{
"input": "10 6\n0001112223\n",
"metadata": {
"func_name": null
},
"output": "3\n0000002223\n",
"testtyp... | {
"index": 3,
"solution": "```python\n#------------------------template--------------------------#\nimport os\nimport sys\nfrom math import *\nfrom collections import *\nfrom fractions import *\nfrom bisect import *\nfrom heapq import*\nfrom io import BytesIO, IOBase\ndef vsInput():\n sys.stdin = open('input.txt... |
primeintellect | [
{
"content": "You are a helpful assistant.",
"role": "system"
},
{
"content": "Solve the following coding problem using the programming language python:\n\nA tree is an undirected connected graph without cycles.\n\nLet's consider a rooted undirected tree with n vertices, numbered 1 through n. There ... | code | {
"ground_truth": [
{
"input": "5\n3 2 2 5 3\n",
"metadata": {
"func_name": null
},
"output": "0\n3 2 2 5 3 ",
"testtype": "stdin"
},
{
"input": "8\n2 3 5 4 1 6 6 7\n",
"metadata": {
"func_name": null
},
"output": "2 \n2 3 5 4 4 4 6 7 \... | {
"index": 4,
"solution": "```python\nfrom collections import defaultdict\nfrom sys import stdin,setrecursionlimit\nsetrecursionlimit(10**6)\nimport threading\ndef f(a):\n\tn=len(a)\n\ta=list(map(lambda s:s-1,a))\n\troot=None\n\tfor i in range(len(a)):\n\t\tif a[i]==i:\n\t\t\troot=i\n\tvis=[0]*(n)\n\ttraitors=[]\n... |
primeintellect | [{"content":"You are a helpful assistant.","role":"system"},{"content":"Solve the following coding p(...TRUNCATED) | code | {"ground_truth":[{"input":"200000 26\n","metadata":{"func_name":null},"output":"aazzyyzxyxxzwywxwwzv(...TRUNCATED) | {"index":5,"solution":"```python\ndef createks(k):\n\tks = ['a', 'a']\n\tif k == 1:\n\t\treturn ks\n(...TRUNCATED) |
primeintellect | [{"content":"You are a helpful assistant.","role":"system"},{"content":"Solve the following coding p(...TRUNCATED) | code | {"ground_truth":[{"input":"4 6\n1 4\n2 3\n1 3\n1 2\n3 4\n2 4\n","metadata":{"func_name":null},"outpu(...TRUNCATED) | {"index":6,"solution":"```python\n(n, m) = map(int, input().split())\nE = [[] for _ in range(n)]\nfo(...TRUNCATED) |
primeintellect | [{"content":"You are a helpful assistant.","role":"system"},{"content":"Solve the following coding p(...TRUNCATED) | code | {"ground_truth":[{"input":"8 6\n4 5\n3 5\n2 5\n1 2\n2 8\n6 7\n","metadata":{"func_name":null},"outpu(...TRUNCATED) | {"index":7,"solution":"```python\n(n, m) = [int(x) for x in input().split()]\nvalues = [1] * n\nnode(...TRUNCATED) |
primeintellect | [{"content":"You are a helpful assistant.","role":"system"},{"content":"Solve the following coding p(...TRUNCATED) | code | {"ground_truth":[{"input":"2\n3 8\n10\n","metadata":{"func_name":null},"output":"3\n","testtype":"st(...TRUNCATED) | {"index":8,"solution":"```python\nm = int(input())\nlistValue = input().split()\nx = input().rstrip((...TRUNCATED) |
primeintellect | [{"content":"You are a helpful assistant.","role":"system"},{"content":"Solve the following coding p(...TRUNCATED) | code | {"ground_truth":[{"input":"4\n3 0 3\n4 -3 5\n42 -33 55\n69 -42 146\n","metadata":{"func_name":null},(...TRUNCATED) | {"index":9,"solution":"```python\nimport sys\ninput = sys.stdin.readline\n\nmod = 10 ** 9 + 7\nfor t(...TRUNCATED) |
End of preview. Expand in Data Studio
README.md exists but content is empty.
- Downloads last month
- 5