problem_id
stringlengths
6
6
user_id
stringlengths
10
10
time_limit
float64
1k
8k
memory_limit
float64
262k
1.05M
problem_description
stringlengths
48
1.55k
codes
stringlengths
35
98.9k
status
stringlengths
28
1.7k
submission_ids
stringlengths
28
1.41k
memories
stringlengths
13
808
cpu_times
stringlengths
11
610
code_sizes
stringlengths
7
505
p03272
u358051561
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a, b = map(int, input().split())\nprint(a-b)', 'a, b = map(int, input().split())\nprint(a-b+1)']
['Wrong Answer', 'Accepted']
['s362106071', 's008573046']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 45]
p03272
u361826811
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['\n\nimport sys\n\n# import numpy as np\n\nread = sys.stdin.buffer.read\nreadline = sys.stdin.buffer.readline\nreadlines = sys.stdin.buffer.readlines\n\nN, i = map(int, readline())\nprint(N - i + 1)\n', '\n\nimport sys\n\n# import numpy as np\n\nread = sys.stdin.buffer.read\nreadline = sys.stdin.buffer.readline\nreadlines = sys.stdin.buffer.readlines\n\nN, i = map(int, readline().split())\nprint(N - i + 1)\n']
['Runtime Error', 'Accepted']
['s252613778', 's395024802']
[3188.0, 2940.0]
[18.0, 17.0]
[234, 242]
p03272
u369752439
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a, b = list(map(int, input().strip().split(" ")))\nprint(b-a+1)', 'a, b = list(input().strip().split(" ")\n\nprint(b-a+1)', 'a, b = list(map(int, input().strip().split(" ")))\nprint(a-b+1)']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s580590647', 's644087323', 's251359440']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[62, 52, 62]
p03272
u370867568
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int, input())\nprint(n - i + 1)\n', 'n, i = map(int, input().split())\nprint(n - i + 1)\n']
['Runtime Error', 'Accepted']
['s890659369', 's947474071']
[2940.0, 2940.0]
[18.0, 18.0]
[42, 50]
p03272
u371686382
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N = int(input())\ni = int(input())\nprint(N - i + 1)', 'N,i = map(int, input().split())\nprint(N - i + 1)']
['Runtime Error', 'Accepted']
['s141281811', 's325286515']
[3316.0, 2940.0]
[19.0, 17.0]
[50, 48]
p03272
u374802266
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a=list(map(int(input().split()))\nprint(a[0]-a[1]+1)', 'a=list(map(int,input().split()))\nprint(a[0]-a[1]+1)\n']
['Runtime Error', 'Accepted']
['s238200100', 's135085725']
[2940.0, 2940.0]
[18.0, 17.0]
[51, 52]
p03272
u375500286
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=map(int,input().split())\nprint(b-a+1)', 'a,b=map(int,input().split())\nprint(a-b+1)']
['Wrong Answer', 'Accepted']
['s810871540', 's017889623']
[2940.0, 2940.0]
[17.0, 17.0]
[41, 41]
p03272
u377036395
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i = map(int,input().split())\nprint(i-n+1)', 'n,i = map(int,input().split())\nprint(n-i+1)']
['Wrong Answer', 'Accepted']
['s217659524', 's437208773']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 43]
p03272
u377989038
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, input().split())\n\nif N = 1:\n print(N)\nelse:\n print(N - i + 1)', 'N, i = map(int, input().split())\n\nif N == 1:\n print(N)\nelse:\n print(N - i + 1)\n']
['Runtime Error', 'Accepted']
['s961462005', 's190108222']
[2940.0, 2940.0]
[17.0, 17.0]
[83, 85]
p03272
u379692329
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = [int(x) for x in input().split()]\nprint(N+i-i)', 'N, i = [int(x) for x in input().split()]\nprint(N+1-i)\n']
['Wrong Answer', 'Accepted']
['s602942617', 's873063722']
[2940.0, 2940.0]
[17.0, 17.0]
[53, 54]
p03272
u382176416
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i=map(int,input().split())\nprint(n-i-1)', 'n,i=map(int,input().split())\nprint(n-i+1)']
['Wrong Answer', 'Accepted']
['s352130105', 's176114813']
[2940.0, 2940.0]
[17.0, 17.0]
[41, 41]
p03272
u383450070
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,I=map(it,input().split())\nprint(N-I+1)', 'N,I=map(int,input().split())\nprint(N-I+1)']
['Runtime Error', 'Accepted']
['s355851508', 's726851430']
[2940.0, 2940.0]
[18.0, 17.0]
[40, 41]
p03272
u390618988
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['rom sys import stdin\n\nN, i = [int(x) for x in stdin.readline().rstrip().split()]\n\nprint(N + 1 - i)\n', "from sys import stdin\n\nH, W = [int(x) for x in stdin.readline().rstrip().split()]\n\nA = [list(stdin.readline().rstrip()) for _ in range(H)]\nresult = A\n\ndelete_column = []\ndelete_row = []\n\nfor k in range(W):\n cnt = 0\n for l in A[k]:\n if l == '.':\n cnt += 1\n if cnt == len(A[k]):\n delete_row.append(k)\n\nfor k in range(W):\n cnt = 0\n for l in range(H):\n if A[l][k] == '.':\n cnt += 1\n if cnt == H:\n delete_column.append(k)\n\nfor x in delete_row:\n del result[x]\n\nfor x in delete_column:\n for y in range(len(A)):\n del result[y][x]\n\nfor x in result:\n print(''.join(x))", 'from sys import stdin\n \nN, i = [int(x) for x in stdin.readline().rstrip().split()]\n \nprint(N + 1 - i)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s115888687', 's312934936', 's039109060']
[2940.0, 3064.0, 2940.0]
[17.0, 18.0, 17.0]
[99, 642, 101]
p03272
u393770225
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['l = raw_input().split()\nN = l[0]\ni = l[1]\nprint(N + 1 - i)\n', 'l = input().split()\nN = int(l[0])\ni = int(l[1])\nprint(N + 1 - i)']
['Runtime Error', 'Accepted']
['s686965068', 's916170528']
[2940.0, 2940.0]
[17.0, 17.0]
[59, 64]
p03272
u396976991
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,K=map(int,input().split())\nX=list(map(int,input().split()))\nhidari=0\nmigi=N-1\nif N-K!=0:\n for i in range(N-K):\n if abs(X[hidari])>=abs(X[migi]):\n hidari=hidari+1\n else:\n migi=migi-1\n\nif X[hidari]<0 and X[migi]>0:\n if abs(X[hidari])>=abs(X[migi]):\n print(2*abs(X[migi])+abs(X[hidari]))\n else:\n print(2*abs(X[hidari])+abs(X[migi]))\nelse:\n if abs(X[hidari])>=abs(X[migi]):\n print(abs(X[hidari]))\n else:\n print(abs(X[migi]))', 'n,i=map(int,input().split(" "))\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s317741497', 's781471867']
[3064.0, 2940.0]
[17.0, 17.0]
[465, 44]
p03272
u408375121
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(input().split())\nprint(N - i + 1)', 'n, i = map(int, input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s184540410', 's355707585']
[2940.0, 9156.0]
[18.0, 26.0]
[44, 45]
p03272
u417044660
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, input().split())\nprint(N-i)', 'N, i = map(int, input().split())\nprint(N-i+1)']
['Wrong Answer', 'Accepted']
['s876074054', 's728331585']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 45]
p03272
u431911003
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N=int(input())\ni=int(input())\nj = N - i +1\nprint(j)', 's=input().split()\nN=int(s[0])\ni=int(s[1])\nj = N - i +1\nprint(j)\n']
['Runtime Error', 'Accepted']
['s746598496', 's588833193']
[2940.0, 2940.0]
[17.0, 17.0]
[51, 64]
p03272
u432805419
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a = list(map(int,input().split()))\nprint(a - b + 1)', 'a = list(map(int,input().split()))\nprint(a[0] - a[1] + 1)']
['Runtime Error', 'Accepted']
['s332652258', 's696240284']
[2940.0, 2940.0]
[18.0, 17.0]
[51, 57]
p03272
u455317716
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['h,w = map(int,input().split())\nmap_ = list()\nfor i in range(h):\n map_.append(list(input()))\nflag = True\nwhile flag:\n\n flag = False\n\n for ii in range(len(map_)):\n if set(map_[ii]) == {"."}:\n del map_[ii]\n flag = True\n break\n\n map_t = [list(x) for x in zip(*map_)]\n\n for ii in range(len(map_t)):\n if set(map_t[ii]) == {"."}:\n del map_t[ii]\n flag = True\n break\n\n map_ = [list(x) for x in zip(*map_t)]\n\n\nfor iiii in map_:\n print(*iiii,sep="")', 'n,i = (int(x) for x in input().split())\nprint(n - i + 1 )']
['Runtime Error', 'Accepted']
['s672609008', 's809030224']
[3064.0, 2940.0]
[17.0, 17.0]
[539, 57]
p03272
u455957070
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b = map(int,input().split())\nprint(a+b-1)', 'a,b = map(int,input().split())\nprint(a-b+1)']
['Wrong Answer', 'Accepted']
['s064819378', 's000050269']
[9144.0, 9140.0]
[25.0, 29.0]
[43, 43]
p03272
u469953228
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b = map(int,input())\n\nprint(a-b+1)', 'a,b = map(int,input().split())\n\nprint(a-b+1)']
['Runtime Error', 'Accepted']
['s396348641', 's890125102']
[2940.0, 2940.0]
[17.0, 17.0]
[36, 44]
p03272
u474270503
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i=list(map(int,input().split()))\nprint(N+1-K)\n', 'N, i=list(map(int,input().split()))\nprint(N+1-i)\n']
['Runtime Error', 'Accepted']
['s511707467', 's315917706']
[3316.0, 2940.0]
[19.0, 17.0]
[49, 49]
p03272
u475675023
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['print(int(input())-int(input())+1)', 'a,b=map(int,input().split());print(a-b+1)']
['Runtime Error', 'Accepted']
['s456811770', 's136136210']
[3060.0, 2940.0]
[17.0, 17.0]
[34, 41]
p03272
u495296799
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a', 'N,i=input().split()\nN=int(N)\ni=int(i)\nprint (N-i+1)\n']
['Runtime Error', 'Accepted']
['s695083733', 's015403615']
[2940.0, 2940.0]
[17.0, 17.0]
[1, 52]
p03272
u506287026
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, input())\nprint(N-i+1)\n', 'N, i = map(int, input().split())\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s390410349', 's450092814']
[2940.0, 2940.0]
[17.0, 17.0]
[38, 46]
p03272
u508405635
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, input().split())\n\nprint(N-i)', 'N, i = map(int, input().split())\n\nprint(N-i+1)']
['Wrong Answer', 'Accepted']
['s296113092', 's906650197']
[2940.0, 2940.0]
[17.0, 18.0]
[44, 46]
p03272
u524870111
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['na = lambda: list(map(int, stdin.readline().split()))\nn, i = na()\n\nprint(n - i + 1)', 'import sys\nstdin = sys.stdin\n\nna = lambda: list(map(int, stdin.readline().split()))\nn, i = na()\n\nprint(n - i + 1)']
['Runtime Error', 'Accepted']
['s170287441', 's271012416']
[2940.0, 3316.0]
[17.0, 21.0]
[83, 113]
p03272
u527993431
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i=map(int,input().split())\nprint(N-1+1)', 'N,i=map(int,input().split())\nprint(N-i+1)']
['Wrong Answer', 'Accepted']
['s297902701', 's520141612']
[2940.0, 2940.0]
[17.0, 17.0]
[41, 41]
p03272
u528981315
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['import math\nN,K = map(int, input().split())\na = list(map(int,input().split()))\nl = 0\nr = K - 1\nMin = float("inf")\nfor i in range(N - K + 1):\n if(a[l]*a[r]<=0):\n Min = min(Min,abs(a[l])+abs(a[l]-a[r]),abs(a[r])+abs(a[r]-a[l]))\n elif(l==0):\n if(a[r]*a[r+1]<0 or a[0]>0):\n Min = min(Min,abs(a[l])+abs(a[l]-a[r]),abs(a[r])+abs(a[r]-a[l]))\n elif(r==N-1):\n if(a[l-1]*a[l]<0 or a[l]>0):\n Min = min(Min,abs(a[l])+abs(a[l]-a[r]),abs(a[r])+abs(a[r]-a[l]))\n else:\n if(a[r]*a[r+1]<0 or a[l-1]*a[l]<0):\n Min = min(Min,abs(a[l])+abs(a[l]-a[r]),abs(a[r])+abs(a[r]-a[l]))\n l = l + 1\n r = r + 1\nprint(Min)\n', 'y = input().split()\nprint(int(y[0])-int(y[1])+1)\n']
['Runtime Error', 'Accepted']
['s265086474', 's206064337']
[3064.0, 2940.0]
[18.0, 17.0]
[716, 49]
p03272
u533039576
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['from bisect import bisect_left\n\nn, k = map(int, input().split())\nx = list(map(int, input().split()))\nif 0 in x:\n x.remove(0)\n k -= 1\n n -= 1\n\nif n == 0:\n print(0)\nelse:\n si = bisect_left(x, 0)\n\n ans = x[-1] - x[0]\n if si + k - 1 < len(x):\n ans = min(ans, x[si + k - 1])\n if si - k >= 0:\n ans = min(ans, abs(x[si - k]))\n\n for i in range(n):\n tmp_ans = 0\n if i < si and i + k -1 < len(x):\n tmp_ans = abs(x[i]) * 2 + x[i + k - 1]\n ans = min(ans, tmp_ans)\n elif i - k + 1 >= 0:\n tmp_ans = x[i] * 2 + abs(x[i - k + 1])\n ans = min(ans, tmp_ans)\n\n print(ans)\n', 'n, i = map(int, input().split())\n\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s431336424', 's782385017']
[3064.0, 2940.0]
[18.0, 17.0]
[661, 46]
p03272
u535423069
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['import sys\n \nstdin = sys.stdin\ninf = 1 << 60\nmod = 1000000007\n \nni = lambda: int(ns())\nnin = lambda x: [ni() for _ in range(x)]\nna = lambda: list(map(int, stdin.readline().split()))\nnan = lambda x: [na() for _ in range(x)]\nns = lambda: stdin.readline().rstrip()\nnsn = lambda x: [ns() for _ in range(x)]\nnas = lambda: stdin.readline().split()\n\nn = ni()\ni = ni()\n\nprint(n - i + 1)', 'import sys\n \nstdin = sys.stdin\ninf = 1 << 60\nmod = 1000000007\n \nni = lambda: int(ns())\nnin = lambda x: [ni() for _ in range(x)]\nna = lambda: list(map(int, stdin.readline().split()))\nnan = lambda x: [na() for _ in range(x)]\nns = lambda: stdin.readline().rstrip()\nnsn = lambda x: [ns() for _ in range(x)]\nnas = lambda: stdin.readline().split()\n\nn, i = na()\n\nprint(n - i + 1)']
['Runtime Error', 'Accepted']
['s521079469', 's573256400']
[3064.0, 3064.0]
[17.0, 17.0]
[378, 372]
p03272
u536377809
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a=int(input())\nb=int(input())\n\nprint(a-b+1)', 'l=list(map(int,input().split()))\nprint(l[0]-l[1]+1)']
['Runtime Error', 'Accepted']
['s673495086', 's417597370']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 51]
p03272
u537497369
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N.i = list(map(int,input().split()))\nprint(N-i+1)\n', 'N,i = list(map(int,input().split()))\nprint(N-1+1)', 'N,i = list(map(int,input().split()))\nprint(N-i+1)\n']
['Runtime Error', 'Wrong Answer', 'Accepted']
['s399487352', 's697687037', 's159789004']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[50, 49, 50]
p03272
u538739837
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
["import numpy as np\nh,w=map(int,input().split())\nicon=list()\nfor i in range(h):\n icon.append(list(input().split()))\n\nrow=[False]*h\ncol=[False]*w\n\nfor i in range(h):\n for j in range(w):\n if icon[i][j]=='#':\n row[i]=True\n col[j]=True\n\nfor i in range(h):\n if row[i]==True:\n for j in range(w):\n if col[j]==True:\n print(icon[i][j],end='')\n print() ", 'n,i=map(int,input().split())\nprint(n+1-i)']
['Runtime Error', 'Accepted']
['s352442838', 's280785369']
[12392.0, 2940.0]
[152.0, 17.0]
[422, 41]
p03272
u545998622
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N =input(int())\ni =input(int())\nprint(int(N+1-i))', 'N =input(int())\na =input(int())\nprint(N-a+1)', 'N,i = map(int, input().split())\nprint(N-i+1)\n']
['Runtime Error', 'Runtime Error', 'Accepted']
['s316597089', 's350729065', 's992281425']
[2940.0, 2940.0, 2940.0]
[18.0, 18.0, 17.0]
[49, 44, 45]
p03272
u548624367
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['print(int(input())-int(input())+1)', 'print((lambda a:a[0]-a[1]+1)(list(map(int,input().split()))))']
['Runtime Error', 'Accepted']
['s031784559', 's097273510']
[2940.0, 2940.0]
[18.0, 17.0]
[34, 61]
p03272
u549497563
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i=map(int,input(),split())\nprint(N-i+1)', 'N,i=map(int,input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s158810043', 's748151597']
[2940.0, 2940.0]
[17.0, 18.0]
[41, 41]
p03272
u553070631
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=int(input.split())\nprint(a-b+1)', 'a,b= (int(i) for i in input().split()) \nprint(a-b+1)']
['Runtime Error', 'Accepted']
['s034990950', 's605137684']
[2940.0, 2940.0]
[18.0, 20.0]
[35, 53]
p03272
u557612894
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N.i=map(int,input().split())\nprint(N-i+1)', 'N,i=map(int,input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s922945843', 's870434552']
[2940.0, 2940.0]
[18.0, 17.0]
[41, 41]
p03272
u559126797
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i=map(int,input())\nprint(N-i+1)\n', 'N,i=map(int,input().split())\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s170227132', 's651092601']
[3188.0, 2940.0]
[18.0, 17.0]
[34, 42]
p03272
u567124995
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['l = list(map(int, input().split()))\nprint((l[0] + l[1]) -1)\n', 'l = list(map(int, input().split()))\nprint(l[0] + 1 - l[1])\n']
['Wrong Answer', 'Accepted']
['s834711031', 's895493791']
[2940.0, 2940.0]
[17.0, 17.0]
[60, 59]
p03272
u571832343
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=map(int,input())\nprint(int(a-b+1))', 'a,b=map(int,input().split())\nprint(int(a-b+1))']
['Runtime Error', 'Accepted']
['s519867126', 's234482894']
[8952.0, 9156.0]
[20.0, 31.0]
[38, 46]
p03272
u572142121
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=input().split()\nprint(a-b+1)', 'a,b=map(int,input().split())\nprint(a-b+1)']
['Runtime Error', 'Accepted']
['s868983344', 's651768133']
[2940.0, 2940.0]
[17.0, 17.0]
[32, 41]
p03272
u575396065
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['info = input()\ninfo = info.split()\nprint(info)\nbackward = int(info[0]) - int(info[1]) + 1\nprint(backward)', 'info = input()\ninfo = info.split()\nbackward = int(info[0]) - int(info[1]) + 1\nprint(backward)']
['Wrong Answer', 'Accepted']
['s086155166', 's679168866']
[2940.0, 2940.0]
[17.0, 17.0]
[105, 93]
p03272
u576844664
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['inp = input().split(" ")\nprint(int(inp[1]) - int(inp[0]))', 'inp = input().split(" ")\nprint(int(inp[0]) - int(inp[1]) + 1)\n']
['Wrong Answer', 'Accepted']
['s237755819', 's894421207']
[2940.0, 2940.0]
[18.0, 18.0]
[57, 62]
p03272
u580093517
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i = map(int,input().split())\nprint(abs(n-i))', 'n,i = map(int,input().split())\nprint(abs(n-i)+1)']
['Wrong Answer', 'Accepted']
['s263794716', 's685589850']
[2940.0, 2940.0]
[17.0, 17.0]
[46, 48]
p03272
u589432040
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = int(input().split())\nprint(N-i+1)', 'N, i = map(int, input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s002641696', 's593518940']
[2940.0, 2940.0]
[18.0, 17.0]
[40, 45]
p03272
u595289165
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int, input().split())\nans = (n-1) + 1\nprint(ans)', 'n, i = map(int, input().split())\nans = (n-i) + 1\nprint(ans)']
['Wrong Answer', 'Accepted']
['s528466865', 's400068834']
[3064.0, 2940.0]
[17.0, 17.0]
[59, 59]
p03272
u607865971
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['import sys\n\nN, K = [int(x) for x in input().split()]\nx = [int(x) for x in input().split()]\n\nr = 0\nfor idx, xi in enumerate(x):\n r = idx\n\n\nlist = []\n\nS = r - K\nif x[r] == 0:\n S += 1\nS = max(S, 0)\n\nfor s in range(S, r+1):\n e = s + K - 1\n if len(x) <= e:\n break\n list.append(abs(x[e] - x[s]) + abs(x[s]))\n list.append(abs(x[e] - x[s]) + abs(x[e]))\n\nprint(min(list))\n\nsys.exit(0)\n', 'N, i = [int(x) for x in input().split()]\n\nprint(N - i + 1)']
['Runtime Error', 'Accepted']
['s948959363', 's023057931']
[3064.0, 2940.0]
[17.0, 18.0]
[401, 58]
p03272
u619458041
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
["import sys\n\ndef main():\n input = sys.stdin.readline\n n, i = map(int, input().split())\n print(N-i+1)\n\n\nif __name__ == '__main__':\n main()", "import sys\n\ndef main():\n input = sys.stdin.readline\n n, i = map(int, input().split())\n print(n-i+1)\n\n\nif __name__ == '__main__':\n main()"]
['Runtime Error', 'Accepted']
['s264868933', 's504893363']
[2940.0, 2940.0]
[17.0, 17.0]
[140, 140]
p03272
u623065116
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
["プ\n 問題\n 質問\n 提出\n 提出一覧\n 順位表\n コードテスト\n 解説\n提出 #5696340\n\nソースコード \n\nCopy\nCopy\n\nH,W=map(int,input().split())\n \nl=[]\nfor i in range(H):\n x=input()\n \n if x!='.'*W:\n l.append(x)\n \nrm=[]\nfor i in range(W):\n \n f=True\n for j in range(len(l)):\n if l[j][i]=='#':\n f=False\n \n \n if f:\n rm.append(i)\n \na=[]\nfor x in l:\n for i in rm[::-1]:\n x=x[:i]+x[i+1:]\n a.append(''.join(x))\n \n\nfor i in range(len(a)):\n print(''.join(a[i]))", 'N, i = map(int, input().split())\n\nprint(N-i +1)\n']
['Runtime Error', 'Accepted']
['s471583723', 's332674568']
[2940.0, 2940.0]
[17.0, 17.0]
[623, 48]
p03272
u623601489
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['h,w=map(int,input().split())\nlst=list(input() for i in range(h))\nn_h=h\nfor i in range(len(lst)):\n if "#" not in lst[h-i-1]:\n n_h-=1\n lst.pop(h-i-1)\nlst=list(map(list,lst))\nfor i in range(w):\n T=True\n for b in range(n_h):\n if lst[b][w-i-1]=="#":\n T=False\n break\n if T:\n for b in range(h):\n lst[b].pop(w-i-1)\nfor a in lst:\n print("".join(a))', 'N,i=map(int,input().split())\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s755534463', 's777277886']
[3064.0, 2940.0]
[18.0, 17.0]
[415, 42]
p03272
u625554679
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['line = input().split()\nN = int(line[0])\ni = int(line[1])\n\nprint(n-i+1)\n', 'line = input().split()\nN = int(line[0])\ni = int(line[1])\n\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s497219132', 's665346086']
[2940.0, 2940.0]
[17.0, 17.0]
[71, 71]
p03272
u625963200
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i=map(int,input().split())\nprint(n-1+1)', 'n,i=map(int,input().split())\nprint(n-i+1)']
['Wrong Answer', 'Accepted']
['s535511449', 's914211434']
[2940.0, 2940.0]
[17.0, 18.0]
[41, 41]
p03272
u633548583
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i=map(int,input().split())\nprint(n-i)\n', 'n,i=map(int,input().split())\nprint(n-i+1)\n']
['Wrong Answer', 'Accepted']
['s234219851', 's586627667']
[2940.0, 2940.0]
[17.0, 17.0]
[40, 42]
p03272
u634159866
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, inout().split())\nprint(N-i+1)', 'N, i = map(int, input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s132805072', 's297923934']
[2940.0, 2940.0]
[17.0, 17.0]
[45, 45]
p03272
u634461820
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i = list(map(int,input()))\nprint(N-i+1)\n', 'N,i = list(map(int,input().split()))\nprint(N - i + 1)\n']
['Runtime Error', 'Accepted']
['s731113165', 's141555943']
[2940.0, 2940.0]
[17.0, 17.0]
[42, 54]
p03272
u642418876
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i=map(int,iput().split())\nprint(N-i+1)\n', 'N,i=map(int,input().split())\nprint(int(N)-int(i)+1)\n']
['Runtime Error', 'Accepted']
['s745724171', 's002383771']
[2940.0, 2940.0]
[18.0, 17.0]
[41, 52]
p03272
u643714578
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i=map(int,input().split())\nprint(n-p+1)', 'n,i=map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s658867447', 's333301779']
[2940.0, 2940.0]
[17.0, 17.0]
[41, 41]
p03272
u645181206
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=map(int,input().split(" "))\nprint(a-b)', 'a,b=map(int,input().split(" "))\nprint(a-b+1)\n\n']
['Wrong Answer', 'Accepted']
['s234079735', 's177862326']
[3316.0, 2940.0]
[19.0, 19.0]
[42, 46]
p03272
u652656291
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i = (int,input().split())\nprint(n-i+1)', 'n,i = map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s344162231', 's669723493']
[2940.0, 2940.0]
[18.0, 17.0]
[40, 43]
p03272
u659753499
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i = map(int,input())\nprint(N-i+1)\n', 'N,i = map(int,input().split())\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s967905775', 's339752516']
[3316.0, 2940.0]
[21.0, 17.0]
[36, 44]
p03272
u661246959
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['\ndef main():\n # parse\n N, i = parse() \n # compute\n result = compute(N, i)\n # show result\n print(result)\n\ndef compute(N, i):\n return N + 1 - i\n\ndef parse():\n vars = split_stdin(get_stdin())\n return vars[0], vars[1] \n\ndef get_stdin():\n return input()\n\ndef split_stdin(stdin_val, delim = \' \'):\n return [x for x in stdin_val.split(delim) if x != \'\']\n\nif __name__ == "__main__":\n main()', 'def main():\n # parse\n N, i = parse()\n # compute\n result = compute(N, i)\n # show result\n print(result)\n\ndef compute(N, i):\n return N + 1 - i\n\ndef parse():\n vars = split_stdin(get_stdin())\n return int(vars[0]), int(vars[1])\n\ndef get_stdin():\n return input()\n\ndef split_stdin(stdin_val, delim = \' \'):\n return [x for x in stdin_val.split(delim) if x != \'\']\n\nif __name__ == "__main__":\n main()']
['Runtime Error', 'Accepted']
['s765165241', 's970444486']
[3060.0, 3060.0]
[17.0, 17.0]
[417, 424]
p03272
u661576386
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=map(int,input().split.(""))\nprint(a-b+1)', 'a,b=map(int,input().split.())\nprint(a-b+1)', 'a, b = map(int, input().split())\nprint(a-b+1)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s200874110', 's996136834', 's148125700']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[44, 42, 45]
p03272
u686036872
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['print(eval(input().replace(" ","-")+1))', 'print(eval(input().replace(" ","-"))+1)']
['Runtime Error', 'Accepted']
['s347769998', 's336085431']
[2940.0, 2940.0]
[17.0, 17.0]
[39, 39]
p03272
u688055251
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['(a,b)=input(),input()\nc=int(a)-int(b)+1\nprint(c)', 'a,b=input(),input()\nc=int(a)-int(b)+1\nprint(c)', "import sys\n\n\ndef solve(a, b):\n c=a-b+1\n return(c)\n\ndef readQuestion():\n line = sys.stdin.readline().rstrip()\n [str_a, str_b] = line.split(' ')\n return (int(str_a), int(str_b))\n\ndef main():\n a, b = readQuestion()\n answer = solve(a, b)\n print(answer)\n \nif __name__ == '__main__':\n main()", '(a,b)=input(),input()\nc=int(a)-int(b)+1\nprint(c)', '(a,b)=input(),input()\nc=a-b+1\nprint(c)\n', 'def solve(a,b):\n c=a-b+1\n return(c)', '(a,b)=input(),input()\nc=int(a)-int(b)+1\nprint(c)', '(a,b)=input(),input()\nc=int(a)-int(b)+1\nprint(c)', 'a,b=map(int,input().split())\nt=a-b+1\nprint(t)']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted']
['s029755649', 's141595808', 's291433813', 's439801330', 's483977286', 's523872296', 's771131742', 's958800058', 's288987636']
[2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0]
[20.0, 18.0, 18.0, 20.0, 18.0, 17.0, 16.0, 17.0, 17.0]
[48, 46, 478, 48, 39, 41, 48, 48, 45]
p03272
u693953100
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b=map(int,input())\nprint(a-b+1)', "n, i = map(int, input().split(' '))\nprint(n-i+1)\n"]
['Runtime Error', 'Accepted']
['s305061960', 's006467874']
[3316.0, 2940.0]
[19.0, 18.0]
[33, 49]
p03272
u694422786
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a = int(input())\nb = int(input())\n\nans = a - b + 1\nprint(ans)\n', '\nl = [int(x) for x in input().split( )]\n\nans = l[0] - l[1] + 1\nprint(ans)\n']
['Runtime Error', 'Accepted']
['s331328096', 's429447311']
[2940.0, 2940.0]
[17.0, 18.0]
[62, 74]
p03272
u729938879
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int,input.split())\nprint(n-i+1)', 'n, i = map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s948437333', 's377010315']
[2940.0, 2940.0]
[17.0, 17.0]
[42, 44]
p03272
u733608212
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['\nn, k = map(int, input().split())\nli = list(map(int, input().split()))\nli.append(0)\nli.sort()\nzero_index = li.index(0)\nif zero_index == 0:\n print(li[k])\nelif zero_index == len(li) -1:\n print(abs(li[-k-1]))\nelse:\n near_zero_small = li[zero_index-1]\n near_zero_big = li[zero_index+1]\n li.pop(zero_index)\n ans = 0\n cost = 0\n for i in range(n):\n minimam = li[i]\n maximam = li[i+k-1]\n if (minimam > 0 and maximam > 0 ):\n if minimam == near_zero_big:\n cost = maximam\n elif (minimam < 0 and maximam < 0 ):\n if minimam == near_zero_big:\n cost = abs(minimam)\n else:\n cost = min(abs(minimam), maximam)*2 + max(abs(minimam), maximam)\n if ans > cost or ans == 0:\n ans = cost\n print(ans)', 'n, i = map(int, input().split())\n\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s121012480', 's293907338']
[3064.0, 2940.0]
[17.0, 17.0]
[817, 46]
p03272
u738835924
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N , M = map(int, input())\nprint(N-M+1)', 'N,M = map(int, input().split())\nprint(N-M+1)']
['Runtime Error', 'Accepted']
['s032347349', 's820173177']
[3316.0, 2940.0]
[19.0, 17.0]
[38, 44]
p03272
u740284863
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N i = map(int, input().split())\nprint(N-i+1)', 'N,i = map(int, input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s516706222', 's557940159']
[2940.0, 2940.0]
[17.0, 17.0]
[44, 44]
p03272
u743272507
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a,b = map(int,input().split())\nprint(b-a+1)', 'a,b = map(int,input().split())\nprint(a-b+1)\n']
['Wrong Answer', 'Accepted']
['s808445218', 's238673799']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 44]
p03272
u746419473
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int, input().split())\n\nprint((n-i)+1 if n%2 == 1 else n-i)\n', 'n, i = map(int, input().split())\n\nprint(n-i+1)\n']
['Wrong Answer', 'Accepted']
['s432136603', 's788988073']
[2940.0, 2940.0]
[17.0, 17.0]
[70, 47]
p03272
u748241164
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int,input().split())\n\nprint(N + i - 1)', 'N, i = map(int,input().split())\n\nprint(N + 1 - i)']
['Wrong Answer', 'Accepted']
['s109450684', 's345589938']
[9080.0, 9060.0]
[30.0, 33.0]
[49, 49]
p03272
u748311048
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i=map(int, input().split())\nprint(L-i+1)', 'N,i=map(int, input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s185892420', 's946956864']
[2940.0, 2940.0]
[17.0, 17.0]
[42, 42]
p03272
u766393261
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['# coding: utf-8\n# Your code here!\n\nN,A=map(int,input()split())\nprint(N-A+1)', '# coding: utf-8\n# Your code here!\n\nN,A=map(int,input().split())\nprint(N-A+1)']
['Runtime Error', 'Accepted']
['s293609458', 's863090243']
[2940.0, 2940.0]
[17.0, 17.0]
[75, 76]
p03272
u778814286
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int, input())\n\nprint(n-i+1)', 'n, i = map(int, input().split())\n\nprint(n-i+1)\n']
['Runtime Error', 'Accepted']
['s979360294', 's703465616']
[2940.0, 2940.0]
[17.0, 20.0]
[38, 47]
p03272
u784653601
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i = map(int,input().split())\nans = N - i + 1-2\nprint(ans)\n', 'N,i = map(int,input().split())\nans = N - i + 1\nprint(ans)\n']
['Wrong Answer', 'Accepted']
['s444668630', 's182690542']
[2940.0, 2940.0]
[17.0, 17.0]
[60, 58]
p03272
u786004828
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N = int(input())\ni = int(input())\nprint(int(N+1-i))\n', 'N = int(input())\ni = int(input())\nprint(N+1-i)', 'n,i = map(int,input().split(" "))\nprint(n+1-i)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s709990407', 's924641986', 's841262734']
[2940.0, 2940.0, 3064.0]
[17.0, 17.0, 17.0]
[52, 46, 46]
p03272
u787383401
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, I=map(int, input(). split())\nprint(N-i+1)\n', 'N, i=map(int, input(). split())\nprint(N-i+1)\n']
['Runtime Error', 'Accepted']
['s410667110', 's106418011']
[2940.0, 2940.0]
[17.0, 17.0]
[45, 45]
p03272
u790877102
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N = int(input())\ni = int(input())\n\nprint u N-i+1', 'N = int(input())\ni = int(input())\n\nprint N-i+1', 'N = int(input())\ni = int(input())\n\nprint u N-i+1', 'N = int(input())\ni = int(input())\n\nprint(N-i+1)', 'N = int(input())\ni = int(input())\n\nprint u N-i+1', 'n, i = map(int,input().split())\nprint (n+i-1)\n', 'n, i = map(int,input().split())\nprint (N+i-1)', 'N, i = map(int,input().split())\n\nprint(N-i+1)']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Accepted']
['s218690564', 's382587142', 's485231220', 's562479034', 's641269285', 's687553264', 's828971901', 's545682252']
[2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 16.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0]
[48, 46, 48, 47, 48, 46, 45, 45]
p03272
u791664126
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['l = list(map(input().split()))\nprint(l[0]-l[1]+1)', 'l = list(map(int,input().split()))\nprint(l[0]-l[1]+1)']
['Runtime Error', 'Accepted']
['s609481784', 's752138611']
[2940.0, 2940.0]
[17.0, 17.0]
[49, 53]
p03272
u794173881
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i = map(int,input().spllit())\nprint(n-i+1)', 'n,i = map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s330154039', 's228319865']
[2940.0, 2940.0]
[17.0, 18.0]
[44, 43]
p03272
u797016134
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i = map(int, input())\nprint(n-i+1)', 'n,i = map(int, input().split())\nprint(n-i+1)\n']
['Runtime Error', 'Accepted']
['s351174253', 's181907170']
[2940.0, 2940.0]
[17.0, 17.0]
[36, 45]
p03272
u797550216
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n ,k = map(int(input().split()))\n\nprint(n-k+1)', 'n ,k = map(int,input().split())\n\nprint(n-k+1)']
['Runtime Error', 'Accepted']
['s967418632', 's453765694']
[2940.0, 2940.0]
[18.0, 18.0]
[46, 45]
p03272
u816631826
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n =int(input("enter number of car_train. "))\ni = int(input("enter ith from the front of train . "))\ndef train(n ,i):\n if n == i:\n print (1)\n else :\n print ((n-i)+1)\n\n\n\ntrain(n,i)', 'n=int(input())\n\n\na=int(input())\n\n\nprint(int(n-a+1))', 'a,b=map(int,input().split())\nc="Wingardium Leviosa"\nprint(a-b+1)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s867142510', 's928091221', 's370900842']
[2940.0, 2940.0, 2940.0]
[18.0, 17.0, 17.0]
[199, 51, 64]
p03272
u819529201
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n.i=map(int,input().split())\nprint(n-i+1)', 'n,i=map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s011731714', 's669991326']
[2940.0, 3064.0]
[18.0, 17.0]
[41, 41]
p03272
u827141374
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = map(int, input().split())\nprint(i - N + 1)', 'N, i = map(int(x), input().split())\nprint(i - N + 1)', 'N, i = map(int, input().split())\nprint(N - i + 1)']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s637670968', 's816021593', 's981679306']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[49, 52, 49]
p03272
u830054172
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i=list(map(int,input().split()))\nprint(n-i)', 'n,i=list(map(int,input().split()))\nprint(n-i+1)']
['Wrong Answer', 'Accepted']
['s292746109', 's762977475']
[2940.0, 2940.0]
[17.0, 17.0]
[45, 47]
p03272
u841531687
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['a, b = map(int, input().split())\nprint(b - a + 1)', 'a, b = map(int, input().split())\nprint(a - b + 1)']
['Wrong Answer', 'Accepted']
['s849389589', 's784078826']
[2940.0, 2940.0]
[17.0, 17.0]
[49, 49]
p03272
u847605090
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,I=map(int,input().split())\nprint(N-I+\n', 'n,i=map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s033773124', 's901376825']
[2940.0, 2940.0]
[17.0, 17.0]
[40, 41]
p03272
u853900545
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N,i =map(int(),input().split())\nprint(N-i+1)', 'N,i = map(int,input().split())\nprint(N-i+1)']
['Runtime Error', 'Accepted']
['s622176750', 's670722934']
[2940.0, 2940.0]
[17.0, 17.0]
[44, 43]
p03272
u854946179
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,i =map(int,input().split())\nans=0\nans=n-i+1', 'n,i =map(int,input().split())\nans=0\nans=n-i+1\nprint(ans)']
['Wrong Answer', 'Accepted']
['s940118534', 's688602512']
[2940.0, 2940.0]
[17.0, 17.0]
[45, 56]
p03272
u855985627
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['N, i = input().split(" ")\nprint(N - i + 1)', 'N, i = (int(i) for i in input().split(" "))\nprint(N - i + 1)']
['Runtime Error', 'Accepted']
['s380684758', 's527908693']
[3064.0, 2940.0]
[17.0, 17.0]
[42, 60]
p03272
u858136677
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n,k = map(int,input().split())\nx = list(map(int,input().split()))\n\nl = 0\nr = k-1\nmnm = 1000100010\nwhile r<n:\n a = abs(x[l])+abs(x[l]-x[r])\n b = abs(x[r])+abs(x[r]-x[l])\n if a<=b:\n if a < mnm:\n mnm = a\n else:\n if b < mnm:\n mnm = b\n l += 1\n r += 1\nprint(mnm)', 'n,i = map(int,input().split())\nprint(n-i+1)']
['Runtime Error', 'Accepted']
['s125739767', 's654189218']
[3064.0, 2940.0]
[18.0, 17.0]
[310, 43]
p03272
u859897687
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['print(eval("-".join(input())))', 'print(eval("-".join(input())+"+1"))', 'print(eval(input().replace(" ","-"))+1)']
['Wrong Answer', 'Wrong Answer', 'Accepted']
['s193047561', 's745315346', 's023645922']
[2940.0, 3060.0, 2940.0]
[18.0, 19.0, 17.0]
[30, 35, 39]
p03272
u863370423
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['s=list(map(int,input().split()))\n print(s[0]-s[1]+1)', 'a,b=map(int,input().split())\nprint(a+1-b)\n//Source code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 charactersSource code should be longer than 50 characters', 'def train(n,m):\n return n-m\nn,m= map(int,input().split())\ntrain(n,m)', 'N= int(input())\ni= int(input())\n\nj=N-i+1\n\nprint (j)\n \n', 'def train(n,m):\n return (n-m)+1\nn,m= map(int,input().split())\ntrain(n,m)', 'x=input()\ny=x.split()\ny = list(map(int,y))\nprint(y[0]-y[1]+1)\n']
['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Accepted']
['s522895571', 's526839580', 's534263169', 's556574206', 's835728447', 's947026478']
[2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0, 17.0, 17.0, 17.0]
[55, 467, 71, 57, 75, 62]
p03272
u865413330
2,000
1,048,576
There is an N-car train. You are given an integer i. Find the value of j such that the following statement is true: "the i-th car from the front of the train is the j-th car from the back."
['n, i = map(int,input().split())\n\nprint(n - i)\n', 'n, i = map(int,input().split())\n\nprint(n - i + 1)\n']
['Wrong Answer', 'Accepted']
['s580842700', 's232075288']
[2940.0, 2940.0]
[17.0, 17.0]
[46, 50]