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
p03307
u191874006
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\n\nif(n%2 == 0):\n print(n)\nelse:\n t=1\n while 1:\n t+=1\n n=n*t\n if(n%2==0):\n print(n)\n break\n ', '#!/usr/bin/env python3\n\nn = int(input())\n\nif(n % 2 == 0):\n print(n)\nelse:\n t = 1\n while True:\n t += 1\n n = n*t\n if(n % 2 == 0):\n print(n)\n break;']
['Runtime Error', 'Accepted']
['s675884725', 's913655682']
[3192.0, 2940.0]
[19.0, 17.0]
[136, 197]
p03307
u197968862
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\na = list(map(int,input().split()))\n\nd = 0\nc = []\nfor b in range(0,max(a)+1):\n for i in range(0,len(a)):\n d += abs(a[i]-(b+i+1))\n c.append(d)\n d = 0\nprint(min(c))', 'n = int(input())\nif n % 2 != 0:\n print(n*2)\nelse:\n print(n)']
['Runtime Error', 'Accepted']
['s560770800', 's120254279']
[3060.0, 2940.0]
[17.0, 17.0]
[194, 65]
p03307
u206570055
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N=int(input())\nA = list(map(int, input().split()))\n\nbig = max(A)\nsmall = min(A)\nprint(big - small)\n', 'N=int(input())\nA = list(map(int, input().split()))\n\nbig = max(A)\nsmall = min(A)\nprint(int(big - small))\n', 'N = input()\nA = list(map(int, input().split()))\n\nbig = max(A)\nsmall = min(A)\nprint(abs(big - small))\n', 'N=int(input())\nA = list(map(int, input().split()))\n\nbig = max(A)\nsmall = min(A)\nprint(big - small)\n', 'N = int(input())\nif N % 2 == 0:\n ans = N\nelse:\n ans = N * 2\nprint(ans)']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s186743458', 's489643088', 's564518995', 's681216097', 's020061280']
[2940.0, 2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0, 17.0, 17.0]
[99, 104, 101, 99, 76]
p03307
u207464563
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif N % 2 != 0:\n n *= 2\nprint(N)', 'N = int(input())\nif N % 2 != 0:\n N *= 2\nprint(N)']
['Runtime Error', 'Accepted']
['s109426203', 's391394801']
[2940.0, 2940.0]
[17.0, 17.0]
[51, 51]
p03307
u209620426
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['num = input()\n\nif num % 2 == 0:\n print(num)\nelse:\n print(num*2)', 'num = input()\n\nif num % 2 == 0:\n print(num)\nelse:\n print(num*2)', 'number = int(input())\nnums = list(map(int, input().split(" ")))\n\nprint(max(nums) - min(nums))\n', 'n=int(input());print(n+n*(n%2))']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s089853608', 's492201028', 's884311780', 's396108082']
[2940.0, 3060.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0, 17.0]
[69, 69, 94, 31]
p03307
u213854484
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = input()\nif N%2 == 1:\n print(2*N)\nelse:\n print(N)', 'N = int(input())\nif N%2 == 1:\n print(2*N)\nelse:\n print(N)']
['Runtime Error', 'Accepted']
['s586767203', 's380496537']
[2940.0, 2940.0]
[18.0, 18.0]
[58, 63]
p03307
u215743476
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nif n%2 == 0:\n print(n*2)\nelse:\n print(n)', 'n = int(input())\nif n % 2 == 1:\n print(n*2)\nelse:\n print(n)']
['Wrong Answer', 'Accepted']
['s347348533', 's297738271']
[2940.0, 2940.0]
[17.0, 17.0]
[63, 65]
p03307
u217556271
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import math\nn=int(input())\nl=list(map(int, input().split()))\nfor i in range(n):\n l[i]-=(i+1)\navg=sum(l)/n\nfb=math.floor(avg)\ncb=math.ceil(avg)\nsadf=sadc=0\nfor i in l:\n sadf+=abs(i-fb)\n sadc+=abs(i-cb)\n\nsad=min(sadf, sadc)\nprint(sad)', 'n=int(input())\n\nif n%2==0:\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s634418797', 's735081606']
[3064.0, 3316.0]
[17.0, 19.0]
[241, 60]
p03307
u220345792
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nA = list(map(int, input().split()))\n\nfor i in range(N):\n A[i] -= i+1\n\nA.sort()\nprint(A)\nmedian = A[N//2]\n\nfor i in range(N):\n A[i] -= median\n A[i] = abs(A[i])\nprint(sum(A))', 'N = int(input())\nprint(N if N%2 == 0 else N*2)']
['Runtime Error', 'Accepted']
['s002368134', 's229524937']
[3064.0, 2940.0]
[18.0, 17.0]
[198, 46]
p03307
u220870679
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nA = input() .split()\na = list(A)\nif len(a) == N:\n b = int(max(a))\n s = int(min(a))\n print(b-s)\nelse:\n N, A, a, b, s = FUCK', 'N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Accepted']
['s636962889', 's625699267']
[3060.0, 2940.0]
[17.0, 17.0]
[151, 63]
p03307
u223646582
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import fractions\nN = int(input())\nprint(2 * N / gcd(2,N))', 'import math\nN = int(input())\nprint(math.gcd(2,N))', 'import fractions\nN = int(input())\nprint(2 * N /fractions.gcd(2,N))', 'import fractions\nN = int(input())\nprint(fractions.gcd(2,N))', 'import fractions\nN = int(input())\n\nprint(2*N if N%2==1 else N)']
['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted']
['s147432740', 's650877575', 's767130527', 's934105749', 's996660396']
[5048.0, 2940.0, 5560.0, 5048.0, 5048.0]
[38.0, 17.0, 52.0, 35.0, 37.0]
[57, 49, 66, 59, 62]
p03307
u228223940
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\na = [int(i) for i in input().split()]\n\nval = []\n\nfor i in range(n):\n val.append(a[i]-i)\n\nval.sort()\n#print(val)\n\n#idx = [(val[0],0)]\nidx = []\ncnt = 1\nfor i in range(n-1):\n if val[i] == val[i+1]:\n #cnt += 1\n if i == n-2:\n idx.append((val[i],i+2))\n continue\n else:\n idx.append((val[i],i+1))\n #cnt = 1\n \nans_val = 0\n\nfor i in range(len(idx)):\n if idx[i][1] >= (n) // 2:\n ans_val = idx[i-1][0]\n\n#print(ans_val)\n#exit()\n \nans = 0\nans2 = 0\nans3 = 0\nfor i in range(n):\n ans += abs(a[i]-ans_val-i)\n ans2 += abs(a[i]-ans_val-i+1)\n ans3 += abs(a[i]-ans_val-i-1)\n \n\nprint(min(ans,ans2,ans3))', 'n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s526369135', 's662137914']
[3188.0, 2940.0]
[18.0, 18.0]
[685, 66]
p03307
u234631479
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nif n%2 == 0:\n print(n):\nelse:\n print(2*n)', 'n = int(input())\nif n%2 == 0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s377410266', 's623097700']
[2940.0, 2940.0]
[17.0, 18.0]
[60, 59]
p03307
u243159381
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nif n% !=0:\n print(2*n)\nelse:\n print(n)', 'n=int(input())\nif n%2 !=0:\n print(2*n)\nelse:\n print(n)']
['Runtime Error', 'Accepted']
['s853668374', 's979293107']
[9008.0, 9056.0]
[23.0, 23.0]
[59, 60]
p03307
u263654061
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\n\nif n%2==0:\n print(n)\nelse:\n print(n/2)', 'n=int(input())\n \nif n%2==0:\n print(n)\nelse:\n print(n*2)']
['Wrong Answer', 'Accepted']
['s089327731', 's567048888']
[2940.0, 2940.0]
[17.0, 17.0]
[56, 57]
p03307
u263691873
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = input()\nif N % 2 == 0:\n print(N)\nelse:\n print(2*N)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(2*N)']
['Runtime Error', 'Accepted']
['s361719851', 's994389578']
[2940.0, 2940.0]
[17.0, 17.0]
[56, 61]
p03307
u265939044
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import sys\nimport math\nN = input()\nAList = list(map(int, input().split()))\nlistnum = 1000000000\n\nlow = -1000000000\nhigh = 1000000000\n\nmode = 1\na1 = 0\na2 = 0\nwhile(True):\n p1 = math.floor((abs(low) + abs(high))/3) + low\n p2 = high - math.floor((abs(low) + abs(high))/3) \n\n for j in range(1,int(N)+1):\n a1 += abs(AList[j-1] -(p1 + j))\n for j in range(1,int(N)+1):\n a2 += abs(AList[j-1] -(p2 + j))\n\n if a1 == a2 or abs(a1-a2) == 1:\n print(min(a1,a2))\n sys.exit()\n elif a1 < a2:\n high = p2\n else:\n low = p1 \n a1 = 0\n a2 = 0', 'A = int(input())\n\nif A % 2 == 0:\n print(A)\nelse:\n print(A*2)']
['Runtime Error', 'Accepted']
['s609078141', 's057622765']
[3064.0, 2940.0]
[17.0, 17.0]
[595, 66]
p03307
u266874640
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
[' N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(2 * N)\n', 'from itertools import accumulate\n\nN = int(input())\nA = list(map(int,input().split()))\nA = list(accumulate(A))\nans = []\n\nfor i in range(N-3):\n for j in range(i+1, N-2):\n for k in range(j+1, N-1):\n list = []\n p = A[i]\n q = A[j]-A[i]\n r = A[k]-A[j]\n s = A[-1]-A[k]\n list = [p, q, r, s]\n ans.append(max(list) - min(list))\n\nprint(min(ans))\n', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(2 * N)\n']
['Runtime Error', 'Runtime Error', 'Accepted']
['s770739655', 's838887555', 's453455934']
[2940.0, 3064.0, 2940.0]
[17.0, 18.0, 17.0]
[69, 422, 68]
p03307
u273010357
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nli = list(map(int,input().split()))\nli.sort()\nprint(abs(li[-1]-li[0]))\n', 'n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(2 * n)\n']
['Runtime Error', 'Accepted']
['s183243132', 's587495002']
[2940.0, 2940.0]
[17.0, 17.0]
[88, 65]
p03307
u274615057
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['\ndef main():\n n = int(input())\n if n % 2:\n print(n)\n else:\n print(2 * n)\n \n\nif __name__ == "__main__":\n main()\n', '\ndef main():\n n = int(input())\n if n % 2 == 0:\n print(n)\n else:\n print(2 * n)\n \n\nif __name__ == "__main__":\n main()\n']
['Wrong Answer', 'Accepted']
['s406837156', 's769016549']
[9052.0, 9076.0]
[26.0, 24.0]
[144, 149]
p03307
u275934251
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nprint(n if n%2==1 else 2*n)', 'n=int(input())\nprint(n if n%2==0 else 2*n)']
['Wrong Answer', 'Accepted']
['s452107480', 's625335545']
[2940.0, 2940.0]
[17.0, 17.0]
[42, 42]
p03307
u278492238
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
["from itertools import accumulate\n\ndef S(a, b):\n return cl[b] - (0 if a == 0 else cl[a-1])\n\ndef partial(start, end, last):\n odiff = None\n for c in range(start, end+1):\n p = S(start,c)\n q = S(c+1,end)\n diff = abs(p-q)\n if odiff is None:\n odiff = diff\n if odiff < diff:\n return c, mp, mq\n odiff = diff\n mp = p\n mq = q\n\nif __name__ == '__main__':\n # read input\n n = int(input())\n l = list(map(int, input().split()))\n \n cl = list(accumulate(l))\n clen = len(l)\n\n \n # |------|------|-------|-------|\n # c0 c1 c2\n \n # pick up a c1 (i:i+1) and evaluate\n result = None\n c1 = 1\n c3 = 3\n for i in range(1,clen-2):\n # LEFT\n (c1, mb, mc) = partial(0, i, c1)\n # RIGHT\n c3, md, me = partial(i+1, clen-1, c3)\n\n # evaluate\n diff = abs(max(mb, mc, md, me) - min(mb, mc, md, me))\n if result is None:\n result = diff\n else:\n if result > diff:\n result = diff\n\n print(result)", "def gcd(a, b):\n while (b > 0):\n a, b = b, a%b\n return a\n\ndef lcm(a, b):\n return int(a*b/gcd(a,b))\n\nif __name__ == '__main__':\n r = int(input())\n print(lcm(2, r))"]
['Runtime Error', 'Accepted']
['s298909731', 's441486351']
[3064.0, 2940.0]
[18.0, 17.0]
[1197, 183]
p03307
u280984565
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import math\n\ndef read_line(*types): return [f(a) for a, f in zip(input().split(), types)]\n\nn, = read_line(int)\n\nA = [int(x) for x in input().split()]\n\nAA = [a - (i + 1) for i, a in enumerate(A)]\n\nAA.sort()\n\nif len(AA) % 2 == 0:\n b = int(len(AA) / 2 - 1)\nelse:\n b = int((len(AA) - 1) / 2)\n\nsadness = 0\nfor i, a in enumerate(A):\n # sadness1 += abs(a - (i + b1 + 1))\n # sadness2 += abs(a - (i + b2 + 1))\n sadness += abs(a - (i + AA[b] + 1))\n\nprint(sadness)\n', 'def read_line(*types): return [f(a) for a, f in zip(input().split(), types)]\n\nn, = read_line(int)\n\nif n % 2 == 0:\n print(n)\nelse:\n print(n * 2)\n']
['Runtime Error', 'Accepted']
['s386988427', 's709497373']
[3064.0, 2940.0]
[19.0, 17.0]
[469, 150]
p03307
u284854859
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['# your code goes here\na=int(input())\nif a%2 == 0:\n\tk = a\nelse:\n\tk = a + 1\nwhile k>0:\n\tif k %2== 0 and k % a ==0:\n\t\tprint(k)\n\t\tquit()\n\tk = k + a', 'a=int(input())\nif a%2 == 0:\n\tprint(a)\nelse:\n\tprint(a*2)']
['Time Limit Exceeded', 'Accepted']
['s758126677', 's909303376']
[2940.0, 2940.0]
[2104.0, 18.0]
[143, 55]
p03307
u288948615
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import copy\n\nN = int(input())\nAn = list(map(int, input().split()))\nfor n in range(N):\n An[n] -= (n+1)\n\nAn.sort()\n\nif (N % 2 == 0):\n cent = An[N//2 - 1] + An[N//2] // 2\nelse:\n cent = An[(N-1)//2]\n\nans = sum(An) - N * cent\n\nprint(ans)\n\n', 'N = int(input())\n\nif (N % 2 == 0):\n print(N)\nelse:\n print(2*N)']
['Runtime Error', 'Accepted']
['s380870110', 's662995340']
[3444.0, 2940.0]
[22.0, 17.0]
[243, 68]
p03307
u294385082
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(N+1)', 'N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(2N)', 'N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(2*N)']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s008726164', 's033287898', 's376355307']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[59, 58, 59]
p03307
u295457032
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\n\nif N % 2 = 0:\n print(N)\nelse:\n print(N*2)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(N * 2)']
['Runtime Error', 'Accepted']
['s412312964', 's088430230']
[2940.0, 2940.0]
[17.0, 17.0]
[59, 63]
p03307
u299801457
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import sys\nn=int(input())\na=list(map(int,input().split()))\n\nif n==1:\n print(0)\n sys.exit()\n\ndef abs(a):\n if a<0:\n return -a\n else:\n return a\n\nfor i in range(n):\n a[i]=a[i]-i-1\n\nans=10**12\na.sort()\nif n<50:\n for b in a:\n S=0\n for j in range(n):\n S+=abs(a[j]-b)\n ans=min(ans,S)\n if ans==10**12:\n ans=0\n print(ans)\n sys.exit()\n\nmid=n//2\nif a[mid]<0:\n b_choice=a[mid-20:mid]\nelse:\n b_choice=a[mid:mid+20]\nfor b in range(b_choice):\n S=0\n for j in range(n):\n S+=abs(a[j]-b)\n ans=min(ans,S)\nif ans==10**12:\n ans=0\nprint(ans)', 'import sys\nn=int(input())\na=list(map(int,input().split()))\n\nif n==1:\n print(0)\n sys.exit()\n\ndef abs(a):\n if a<0:\n return -a\n else:\n return a\n\nfor i in range(n):\n a[i]=a[i]-i-1\n\nans=10**12\na.sort()\nif n<20:\n for b in a:\n S=0\n for j in range(n):\n S+=abs(a[j]-b)\n ans=min(ans,S)\n if ans==10**12:\n ans=0\n print(ans)\n sys.exit()\n\nmid=n//2\nif a[mid]<0:\n b_choice=a[mid-20:mid]\nelse:\n b_choice=a[mid:mid+20]\nfor b in b_choice:\n S=0\n for j in range(n):\n S+=abs(a[j]-b)\n ans=min(ans,S)\nif ans==10**12:\n ans=0\nprint(ans)', 'n=int(input())\n\nif n%2==0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s094834750', 's431301861', 's285481012']
[3064.0, 3064.0, 2940.0]
[17.0, 18.0, 17.0]
[622, 615, 60]
p03307
u300465687
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['u = int(input())\nif u % 2 == 1:\n print u*2\nelse:\n print u', 'u = int(input())\nif u % 2 == 1:\n print (u*2)\nelse:\n print (u)']
['Runtime Error', 'Accepted']
['s793972713', 's667430454']
[2940.0, 2940.0]
[17.0, 17.0]
[59, 63]
p03307
u310549140
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['\ndef fact(n):\n if 1<n:\n return n + fact(n-1)\n else:\n return n\n\n\nN = int(input())\nA = list(map(int,input().split()))\nb = int(round(float((sum(A)-fact(N)))/N))\nif b<0:\n b -= 1\n\nans = 0\n\nfor i in range(N):\n ans += abs(A[i]-(b+i+1))\n\nprint(ans)', 'N = int(input())\nif N%2==0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Accepted']
['s597672622', 's078345742']
[3064.0, 2940.0]
[17.0, 18.0]
[254, 57]
p03307
u323680411
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\n\nprint(N + N % 2)', 'N = int(input())\n\nprint(N * 2 ** (N % 2))']
['Wrong Answer', 'Accepted']
['s773928030', 's561251647']
[2940.0, 2940.0]
[17.0, 17.0]
[34, 41]
p03307
u326261815
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=input()\nif n%2==0:\n print(n)\nelse:\n print(n*2)', 'n=input()\nif int(n)%2==0:\n print(n)\nelse:\n print(n*2)\n ', 'n=input()\nif int(n)%2==0:\n print(n)\nelse:\n print(int(n)*2)\n ']
['Runtime Error', 'Wrong Answer', 'Accepted']
['s191854029', 's618444550', 's291539195']
[8804.0, 9148.0, 9120.0]
[25.0, 28.0, 29.0]
[50, 58, 63]
p03307
u331036636
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['def abc(N):\n if N % 2 == 0:\n return N\n else:\n return N * 2', 'N = input()\nif N % 2 == 0:\n print(N)\nelse:\n print(N*2)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(N * 2)']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s736014416', 's898442363', 's470042260']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 18.0]
[78, 56, 67]
p03307
u334712262
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(intpu())\nif N % 2 == 0:\n print(N)\nelse:\n print(N*2)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Accepted']
['s282660783', 's739104217']
[2940.0, 2940.0]
[18.0, 17.0]
[61, 61]
p03307
u338107614
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\na = list(map(int, input().split()))\nl_abs = []\nmax_v = 0\nfor i, a_i in enumerate(a):\n if(max_v < a_i):\n max_v = a_i\n l_abs.append(abs((i+1)-a_i))\n\nmin = 10 ** 16\nif sum(l_abs) == 0:\n min = 0\nelse:\n for b in range(-(max_v+1), max_v+1):\n sum = 0\n for j, a_j in enumerate(a):\n sum += abs(a_j-(b+j+1))\n if(min > sum):\n min = sum\nprint(min)\n', 'n = int(input())\nif(n%2==0):\n print(str(n))\nelse:\n print(str(n * 2))\n']
['Runtime Error', 'Accepted']
['s852380289', 's588205736']
[3064.0, 2940.0]
[17.0, 17.0]
[415, 75]
p03307
u345076485
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import statistics\nimport math\n\nN = int(input())\nA = list(map(int, input().split()))\n\nB = []\nC = []\nD = []\nE = []\nureshimi = []\nk = 0\nl = 0\n\nfor i in range(N-3):\n BC = A[0 : i + 2]\n s = 0\n for j in range(k, i + 2):\n s += BC[j]\n if j == i + 1:\n k = j \n B = BC[0 : j ]\n C = BC[j : N - i]\n break\n elif s + BC[j + 1] > sum(BC) / 2:\n k = j\n if BC[j + 1] / 2 >= sum(BC) / 2 - s:\n B = BC[0 : j + 1]\n C = BC[j + 1 : i + 2]\n else:\n B = BC[0 : j + 2]\n C = BC[j + 2 : i + 2]\n break\n DE = A[i + 2 : N + 1]\n s = sum(DE[0:l - i + 1 ])\n for j in range(l - i + 1 , N - i - 2):\n if j == N - i - 3:\n l = j + i \n D = DE[0 : j ]\n E = DE[j : N - i]\n break\n elif s + DE[j ] > sum(DE) / 2:\n l = j + i\n if DE[j ] / 2 >= sum(DE) / 2 - s:\n D = DE[0 : j ]\n E = DE[j : N - i]\n else:\n D = DE[0 : j + 1]\n E = DE[j + 1 : N - i]\n break\n s += DE[j]\n ureshimi.append(max(sum(B), sum(C), sum(D), sum(E)) - min(sum(B), sum(C), sum(D), sum(E)))\n\n\n\nprint(min(ureshimi))', 'N = int(input())\n\nif N % 2 == 0:\n print(N)\nelse:\n print(N * 2)']
['Runtime Error', 'Accepted']
['s502371266', 's861180789']
[5404.0, 2940.0]
[40.0, 17.0]
[1291, 68]
p03307
u350049649
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N=int(input())\nprint(N*2 if N%==1 else N)', 'N=int(input())\nprint(N*2 if N%2==1 else N)\n']
['Runtime Error', 'Accepted']
['s698266762', 's254407408']
[2940.0, 2940.0]
[18.0, 17.0]
[41, 43]
p03307
u353919145
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['num = int(input())\n \nif num%2 != 0:\n print(str(num))\nelse:\n print(str(2*num))', 'line = input()\nnum = [int(n) for n in line.split()]\n\nsmaller_divisible_number = num\nif num%2 != 0:\n smaller_divisible_number *= 2\nprint(smaller_divisible_number)', 'num = int(input())\n \nelif num%2 != 0:\n print(str(num))\nelse:\n print(str(2*num))', 'a = int(input())\nif not a % 2:\n print(a)\nelse:\n print(a * 2)']
['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted']
['s138739312', 's180125027', 's797504918', 's737872418']
[2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0, 18.0]
[84, 164, 86, 66]
p03307
u354918239
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nA = input().split()\nfor i in range(len(A)) :\n A[i] = int(A[i])\nprint(max(A)-min(A))', 'N = 10\nfor i in range(1,int(10e8)) :\n if (i % 2) == 0 :\n if (i % N) == 0 :\n print(i)\n break', 'n = int(input())\nif n % 2 == 0 :\n print(n)\nelse :\n print(n * 2)']
['Runtime Error', 'Wrong Answer', 'Accepted']
['s080448520', 's657244360', 's717585314']
[2940.0, 2940.0, 2940.0]
[18.0, 17.0, 17.0]
[103, 123, 69]
p03307
u357810840
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['if a % 2 == 0:\n b = a\nelse:\n b = 2*a\nprint(b)', 'from statistics import *\n\n\n\nn = int(input())\nlist = input().split()\n\nfor i in range(n):\n list[i] = int(list[i]) - (i + 1)\n\nb = int(median(list))\n\nfor i in range(n):\n list[i] = abs(list[i] - b)\n\nprint(sum(list))\n\n', 'a = int(input())\n\nif a % 2 == 0:\n b = a\nelse:\n b = 2*a\nprint(b)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s255586068', 's749029923', 's858275583']
[2940.0, 5144.0, 2940.0]
[17.0, 35.0, 17.0]
[51, 218, 69]
p03307
u366644013
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nif n % 2 == 0:\n print(n)\nelse:\n print(n**2)', 'n = int(input())\nif n % 2 == 0:\n print(n)\nelse:\n print(n**2)', 'n = int(input())\nif n % 2 == 0:\n print(n)\nelse:\n print(n*2)']
['Wrong Answer', 'Wrong Answer', 'Accepted']
['s168862008', 's724366087', 's824274364']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[66, 66, 65]
p03307
u366959492
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nx=0\nwhile x%n!=0:\n x+=2\n\nprint(x)', 'n=int(input())\nif n%2==0:\n print(n)\nelse:\n print(n*2)\n']
['Wrong Answer', 'Accepted']
['s675958920', 's537511251']
[2940.0, 2940.0]
[17.0, 17.0]
[51, 60]
p03307
u366964431
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
["import numpy as np\n#import pdb\n\nN = int(input())\ntmp = input().split(' ')\n\nA = []\nfor i in range(N):\n A.append(int(tmp[i]))\n\nA = np.asarray(A)\n\nz = np.asarray([x for x in range(N)])\nA = A - z\n\nb_ceil = np.ceil(np.median(A)).astype(np.int32)\nb_floor = np.floor(np.median(A)).astype(np.int32)\n\nA_ceil = A - b_ceil\nA_ceil = np.absolute(A_ceil)\nA_floor = A - b_floor\nA_floor = np.absolute(A_floor)\n\n#pdb.set_trace()\nprint(np.min((A_ceil.sum(), A_floor.sum())).astype(np.uint32))", 'N = input()\nif N % 2 == 0:\n print(N)\nelse:\n print(N * 2)', "import numpy as np\n\nN = int(input())\ntmp = input().split(' ')\n\nA = []\nfor i in range(N):\n A.append(int(tmp[i]))\n\nA = np.asarray(A)\nprint(A.max() - A.min())", "import numpy as np\n\nN = int(input())\ntmp = input().split(' ')\n\nA = []\nfor i in range(N):\n A.append(int(tmp[i]))\n\nA = np.asarray(A)\n\nz = np.asarray([x for x in range(N)])\nA = A - z\n\nb = np.median(A)\nA = A - b\nA = np.abs(A)\nprint(A.sum().astype(np.uint8))\n", 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(N * 2)']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s106560428', 's147564115', 's459553436', 's895568464', 's059066982']
[12500.0, 2940.0, 12396.0, 13404.0, 2940.0]
[148.0, 17.0, 151.0, 156.0, 17.0]
[477, 62, 158, 257, 67]
p03307
u372345564
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\na = [int(_) for _ in input().split()]\n\nsub_num = [0]*(2*10**6)\n\nfor i in range(1, n+1):\n# print(abs(int(a[i-1]-i)))\n sub_num[abs(int(a[i-1]-i))] += 1\n\nb = -sub_num.index(max(sub_num))\n#print(b)\n\nresult = 0\nfor i in range(1, n+1):\n result += abs(a[i-1] - (b + i))\n\nprint(result)', 'n = int(input())\n\nif(n % 2 == 0):\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s967319306', 's637784794']
[3064.0, 2940.0]
[18.0, 17.0]
[303, 67]
p03307
u374146618
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nin n%2==0:\n print(n)\nelse:\n print(2*n)', 'n = int(input())\nif n%2==0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s628502696', 's615548966']
[2940.0, 2940.0]
[17.0, 17.0]
[61, 61]
p03307
u375616706
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['if N%2==0:\n\tprint(N)\nelse:\n\tprint(2*N)', 'print(map(lambda x:x*((x%2*2),int(input()))', 'def median_low(A):\n A.sort()\n b=A\n n = len(A)\n if n%2==1:\n med =b[n//2]\n else:\n x=b[n//2-1]\n y=b[n//2]\n med=(x+y)/2\n if med!=int(med):\n med=x\n else:\n med=int(med)\n return med\n\n\nn = (int)(input())\nA = (list)(map(int,input().split()))\n\nA = [v-i-1 for i,v in enumerate(A)]\nx = median_low(A)\n\nprint(sum(abs(v - x) for v in A))\n\n', 'print((lambda x:x+x*(x%2)))(int(input()))', '\nusing namespace std;\n\nint main(){\n int n;\n cin >> n;\n if (n%2==0){\n cout<< n << endl;\n }else{\n cout << 2*n <<endl;\n }\n}\n', 'print((lambda x:x+x*(x%2))(int(input())))']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s138851901', 's369756235', 's570488062', 's590574192', 's912284859', 's583107971']
[2940.0, 2940.0, 3064.0, 2940.0, 2940.0, 2940.0]
[17.0, 17.0, 18.0, 17.0, 18.0, 18.0]
[38, 43, 406, 41, 168, 41]
p03307
u377158682
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
["def B():\n n = int(input())\n a = input().split()\n \n if(len(a) != n):\n exit(1)\n\n i_max = 0\n i_min = 1000000001\n for i in a:\n k = int(i)\n if (i_max < k):\n i_max = k\n if (i_min > k):\n i_min = k\n print(i_max,i_min)\n print(abs( i_max - i_min))\n\nif __name__ =='__main__':\n B()", "\nif __name__ =='__main__':\n a = input()\n try:\n x = int(a)\n except:\n exit(1)\n\n if(x % 2 != 0):\n x = x*2\n \n print(x)"]
['Runtime Error', 'Accepted']
['s541764988', 's952710195']
[3060.0, 2940.0]
[17.0, 17.0]
[357, 154]
p03307
u378235715
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nA = input()\nb = A.split(" ")\nc = []\nfor i in range(0,N):\n c.append(abs(int(b[i])))\n\nc.sort\n\nprint(int(c[-1])-int(c[0]))', 'N = int(input())\nA = input()\nb = A.split(" ")\nc = []\nfor i in range(0,N):\n c.append(abs(int(b[i])))\nc.sort\n\nprint(c[-1]-c[0])', 'N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s192829686', 's785960966', 's761460216']
[3060.0, 3060.0, 2940.0]
[17.0, 17.0, 17.0]
[139, 128, 63]
p03307
u379142263
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['import sys\nimport itertools\nimport funtools\nsys.setrecursionlimit(1000000000)\nfrom heapq import heapify,heappop,heappush,heappushpop\nimport math\nimport collections\n\nn = int(input())\nif n%2 == 0:\n print(n)\nelse:\n print(2*n)', 'import sys\nimport itertools\nsys.setrecursionlimit(1000000000)\nfrom heapq import heapify,heappop,heappush,heappushpop\n\nimport collections\n\nn = int(input())\nif n%2 == 0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s077676300', 's324520044']
[3060.0, 3316.0]
[18.0, 21.0]
[228, 201]
p03307
u380761558
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['m = int(input())\na = list( map( int, input().split() ) )\nb1 = a[0]\nb2 = a[0]\nfor i in range(m):\n if a[i] > b1:\n b1 = a[i]\n elif a[i] < b2:\n b2 = a[i]\nprint(b1-b2)', 'm = int(input())\nif m %2 == 1:res = m*2\nelse:res = m\nprint(res)']
['Runtime Error', 'Accepted']
['s123030088', 's448834706']
[3060.0, 2940.0]
[17.0, 17.0]
[170, 63]
p03307
u381680991
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nA = list(map(int,input().split()))\nB = [it - (idx + 1) for idx, it in enumerate(A)]\nS = []\n\nfor b in B:\n C = [abs(i-b) for i in B]\n s = sum(C)\n S.append(s)\n \nprint(min(S))', 'N = int(input())\n\nif N%2 == 0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Accepted']
['s730596370', 's278304230']
[3060.0, 2940.0]
[17.0, 18.0]
[200, 64]
p03307
u390618988
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['from sys import stdin\n\nN = int(stdin.readline().rstrip())\nA = [int(x) for x in stdin.readline().rstrip().split()]\n\nfor k in range(N):\n A[k] -= k\n\nA.sort()\n\n\ndef get_pity_sum(x):\n pity_sum = 0\n for l in A:\n if A[x] - l >= 0:\n pity_sum += A[x] - l\n else:\n pity_sum += l - A[x]\n return pity_sum\n\n\nif N % 2 == 1:\n print(min(get_pity_sum(int((N - 1) / 2)), get_pity_sum(int((N - 1) / 2 - 1)), get_pity_sum(int((N - 1) / 2 + 1))))\nelse:\n print(min(get_pity_sum(int(N / 2)), get_pity_sum(int(N / 2 - 1))))\n', 'from sys import stdin\n\nN = int(stdin.readline().rstrip())\n\nif N % 2 == 0:\n print(N)\nelse:\n print(2 * N)\n']
['Runtime Error', 'Accepted']
['s948241186', 's778731791']
[3064.0, 2940.0]
[17.0, 17.0]
[553, 110]
p03307
u393881437
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['s = 2\nn = int(input())\n\n\ndef gcd(a, b):\n x = max(a, b)\n y = min(a, b)\n if x % y == 0:\n return y\n else:\n while x % y != 0:\n z = x % y\n x = y\n y = z\n else:\n return z\n\n\ndef lcm(a, b):\n print(gcd(a, b))\n return int(a * b / gcd(a, b))\n\n\nprint(lcm(s, n))\n', 's = 2\nn = int(input())\n\na = int(input())\nif a % 2 == 1:\n print(a*2)\nelse:\n print(a)', 'a = int(input())\nif a % 2 == 1:\n print(a*2)\nelse:\n print(a)']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s042926989', 's575645031', 's694433426']
[2940.0, 3060.0, 2940.0]
[17.0, 17.0, 17.0]
[332, 89, 65]
p03307
u395086545
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = input()\n\nif n % 2 == 0:\n print(n)\nelse:\n print(2*n)', 'n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s915315729', 's581220773']
[2940.0, 2940.0]
[17.0, 17.0]
[57, 62]
p03307
u395202850
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['print(n if n % 2 == 0 else n * 2)\n', 'n = int(input())\nprint(n if n % 2 == 0 else n * 2)\n']
['Runtime Error', 'Accepted']
['s166758024', 's729731233']
[2940.0, 2940.0]
[17.0, 17.0]
[34, 51]
p03307
u395237353
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif n%2 == 0:\n print(N)\nelse:\n print(N*2)', 'N = int(input())\n\nif N%2 == 0:\n\tprint(N)\nelse:\n\tprint(N*2)']
['Runtime Error', 'Accepted']
['s816205889', 's838964022']
[2940.0, 3064.0]
[17.0, 17.0]
[59, 58]
p03307
u403984573
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif N % 2 = 0:\n print(N)\nelse print(N*2)', 'N = int(input())\nif N % 2 = 0:\n print(N)\nelse:\n print(N*2)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s091860729', 's180314067', 's917475545']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[57, 60, 61]
p03307
u407535999
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['a=input()\nd=a\nif a>2:\nelse \n b=a\n a=2\nwhile c!=0:\n c=a%b\n a=b\n b=c\nprint(d*2/b)\n', 'a=input()\na=int(a)\nd=a\nif a<2:\n b=a\n a=2\nelse\n b=2\nc=1\nwhile c!=0:\n c=a%b\n a=b\n b=c\nprint(d*2/b)\n#a=2,b=1,c=1,d=1', 'a=input()\na=int(a)\nif a%2==0:\n print(a)\nelse\n print(a*2)', 'N=input()\nif N%2==0:\n print(N)\nelse:\n print(N*2)\n ', 'a=input()\na=int(a)\nd=a\nif a<2:\n b=a\n a=2\nwhile c!=0:\n c=a%b\n a=b\n b=c\nprint(d*2/b)\n', 'a=input()\nif a>2:\nelse \n b=a\n a=2\nwhile c!=0:\n c=a%b\n a=b\n b=c\nprint(b)\n ', 'a=input()\na=int(a)\nd=a\nif a<2:\n b=a\n a=2\nelse\n b=2\nwhile c!=0:\n c=a%b\n a=b\n b=c\nprint(d*2/b)\n', 'a=input()\nif a%2==0:\n print(a)\nelse\n print(a*2)', 'N=input()\nN=int(N)\nif N%2==0:\n print(N)\nelse:\n print(N*2)\n ']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s042186374', 's106887531', 's691973000', 's718177600', 's800270850', 's845288669', 's873057587', 's919791725', 's222882835']
[2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 18.0, 17.0, 17.0, 18.0, 17.0, 18.0, 18.0, 17.0]
[95, 131, 62, 59, 98, 91, 111, 53, 68]
p03307
u409064224
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['a = int(input())\n\nif a % 2 ==0:\n print(n)\nelse:\n print(n*2)', 'a = int(input())\n\nif a % 2 ==0:\n print(a)\nelse:\n print(a*2)\n']
['Runtime Error', 'Accepted']
['s326063031', 's607367229']
[2940.0, 2940.0]
[17.0, 17.0]
[61, 66]
p03307
u411544692
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['print(2*N if N%2==1 else N)', 'print(2*N if N%2==0 else N)', 'N = int(input())\nprint(2*N if N%2==1 else N)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s119472612', 's474003517', 's525430025']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[27, 27, 44]
p03307
u418527037
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = input()\n\nimport math\n\nlcm = lambda a, b: a * b // math.gcd(a, b)\n\nlcm(2, N)', 'N = input()\n\nimport math\n\nlcm = lambda a, b: a * b // math.gcd(a, b)\n\nprint(lcm(2, N))', 'N = int(input())\n\ngcd = lambda a, b: gcd(b, a % b)\n\nlcm = lambda a, b: a * b // math.gcd(a, b)\n\nlcm(2, N)', 'N = int(input())\n\nif N % 2 == 0:\n print(N)\nelse:\n print(2*N)']
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
['s118545207', 's162639217', 's371744120', 's098103725']
[2940.0, 2940.0, 2940.0, 2940.0]
[17.0, 17.0, 18.0, 17.0]
[79, 86, 105, 66]
p03307
u433780933
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = input()\ni = 2\nwhile True:\n if i%2==0 and i%n==0:\n print(i)\n break\n i +=1', 'n = int(input())\nif n%2==0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s425920665', 's640783273']
[2940.0, 2940.0]
[17.0, 17.0]
[84, 57]
p03307
u440478998
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['def lcm_base(x,y):\n return (x * y) // math.gcd(x,y)\n\ndef n_lcm(*numbers):\n print(reduce(lcm_base,numbers,1))\n \nn_lcm(2,int(input()))', 'import math\n\ndef lcm_base(x,y):\n return (x * y) // math.gcd(x,y)\n\nprint(lcm_base(2,int(input())))']
['Runtime Error', 'Accepted']
['s900420446', 's142197518']
[8944.0, 9052.0]
[27.0, 29.0]
[141, 100]
p03307
u442948527
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nm=max(n,2)+1\nwhile 1:\n if m%2 and m%n:\n print(m)\n m+=1', 'n=int(input())\nm=max(n,2)+1\nwhile 1:\n if m%2 and m%n:\n print(m)\n break\n m+=1', 'n=int(input())\nprint(n*(1+n%2))']
['Time Limit Exceeded', 'Wrong Answer', 'Accepted']
['s031584449', 's867522559', 's568053854']
[54420.0, 9148.0, 9120.0]
[2280.0, 2205.0, 28.0]
[82, 96, 31]
p03307
u449555432
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['a=int(input())\nif a%2==0:\n print(a)\nelse:\n print(2a)', 'a=int(input())\nif a%2==0:\n print(a)\nelse:\n print(2*a)']
['Runtime Error', 'Accepted']
['s061333005', 's866269379']
[2940.0, 2940.0]
[17.0, 17.0]
[54, 55]
p03307
u451017206
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['999999999', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(2*N)']
['Wrong Answer', 'Accepted']
['s670066257', 's279877422']
[2940.0, 2940.0]
[17.0, 17.0]
[9, 65]
p03307
u452015170
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nprint(min(n, 2 *n))', 'n = int(input())\nif (n % 2) == 0 :\n print(n)\nelse :\n print(2 * n)']
['Wrong Answer', 'Accepted']
['s545080823', 's140586445']
[2940.0, 2940.0]
[17.0, 17.0]
[36, 71]
p03307
u453068434
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nnum=n\nwhile(num%n!=0 and num%2!=0):\n num+=1\nprint(num)', 'n=int(input())\nnum=n\nif(num%n==0 and num%2==0):\n print(num)\nelse:\n while(num%n!=0 or num%2!=0):\n num+=n\n print(num)']
['Wrong Answer', 'Accepted']
['s581149106', 's564790698']
[2940.0, 2940.0]
[17.0, 17.0]
[72, 131]
p03307
u454481887
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = input\nif n % 2 = 1:\n print(n * 2)\nelse:\n print(n)', 'n = int(input())\nif n % 2 == 1:\n print(n * 2)\nelse:\n print(n)']
['Runtime Error', 'Accepted']
['s655829072', 's258006615']
[2940.0, 2940.0]
[17.0, 17.0]
[59, 67]
p03307
u455957070
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=input()\nprint(n+n)', 'n=input()\nif(n%2==0):\nprint(n)\nelse:\n print(2*n)\n', 'n = int(input())\nif n%2==0:\n print(n)\nelse:\n print(2*n)\n']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s019622735', 's850053662', 's800388728']
[9088.0, 8864.0, 9144.0]
[28.0, 22.0, 27.0]
[20, 52, 62]
p03307
u461636820
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nprint(N if N % 2 else N*2)', 'N = int(input())\nprint(N if N % 2==0 else N*2)']
['Wrong Answer', 'Accepted']
['s136976037', 's170634040']
[2940.0, 2940.0]
[17.0, 17.0]
[43, 46]
p03307
u466335531
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N=int(input())\nA=list(map(int, input().split()))\n\na0=A[1:N-1]\na1n=A[0]\na2n=A[-1]\na1=A[0]\na2=A[-1]\nwhile True:\n if a0==[]:break\n if a1n<a2n:\n a1n+=a0[0]\n a1.append(a0[0])\n a0.pop(0)\n else:\n a2n+=a0[-1]\n a2.insert(0,a0[0])\n a0.pop(-1)\n \na3n=a1[0]\na4n=a1[-1]\nwhile True:\n if a1==[]:break\n elif a3n<a4n:\n a3n+=a1[0]\n a1.pop(0)\n else:\n a4n+=a1[-1]\n a1.pop(-1)\n \na5n=a2[0]\na6n=a2[-1]\nwhile True:\n if a2==[]:break\n elif a5n<a6n:\n a5n+=a2[0]\n a2.pop(0)\n else:\n a6n+=a2[-1]\n a2.pop(-1)\n \nnum=[sum(a3),sum(a4),sum(a5),sum(a6)]\nprint(max(num)-min(num))', 'N=int(input())\nA=list(map(int, input().split()))\n\na0=A[1:N-1]\na1n=A[0]\na2n=A[-1]\na1=A[0]\na2=A[-1]\nwhile True:\n if a0==[]:break\n if a1n<a2n:\n a1n+=a0[0]\n a1.append(a0[0])\n a0.pop(0)\n else:\n a2n+=a0[-1]\n a2.insert(0,a0[0])\n a0.pop(-1)\n \na3n=a1[0]\na4n=a1[-1]\nwhile True:\n if a1==[]:break\n elif a3n<a4n:\n a3n+=a1[0]\n a1.pop(0)\n else:\n a4n+=a1[-1]\n a1.pop(-1)\n \na5n=a2[0]\na6n=a2[-1]\nwhile True:\n if a2==[]:break\n elif a5n<a6n:\n a5n+=a2[0]\n a2.pop(0)\n else:\n a6n+=a2[-1]\n a2.pop(-1)\n \nnum=[sum(a3),sum(a4),sum(a5),sum(a6)]\nprint(max(num)-min(num))', 'N=int(input())\nprint((N%2+1)*N)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s536401240', 's777982382', 's103223992']
[3064.0, 3064.0, 2940.0]
[18.0, 17.0, 17.0]
[687, 687, 31]
p03307
u475077336
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\nan = [int(i) for i in input().split()]\nprint(sum(an)-n)\n', 'def gcd(a, b):\n\twhile b:\n\t\ta, b = b, a % b\n\treturn a\ndef lcm(a, b):\n\treturn a * b // gcd (a, b)\nn = int(input())\nprint(lcm(2,n))']
['Runtime Error', 'Accepted']
['s565956009', 's349423314']
[2940.0, 2940.0]
[18.0, 18.0]
[73, 128]
p03307
u476199965
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['a = print()\nif a%2 ==0:print(a)\nelse:print(2*a)', 'a = int(print())\nif a%2 ==0:print(a)\nelse:print(2*a)\n', 'a = input()\na = int(a)\nif a%2 ==0:print(a)\nelse:print(2*a)\n']
['Runtime Error', 'Runtime Error', 'Accepted']
['s064018126', 's792704625', 's747292179']
[2940.0, 2940.0, 2940.0]
[17.0, 17.0, 17.0]
[47, 53, 59]
p03307
u477320129
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nprint(N if N % 2 else 2 * N)', 'N = int(input())\nprint(N if N % 2 == 0 else 2 * N)']
['Wrong Answer', 'Accepted']
['s436831177', 's138060932']
[9092.0, 9136.0]
[32.0, 29.0]
[45, 50]
p03307
u480847874
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['def m():\n n = int(input())\n if n % 2 == 0:\n return n\n return n*2', 'def m():\n n = int(input())\n if n % 2 == 0:\n return n\n return n*2\n\nprint(m())']
['Wrong Answer', 'Accepted']
['s279471487', 's131332733']
[2940.0, 2940.0]
[17.0, 17.0]
[80, 92]
p03307
u488380455
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\ni = n % 2\n\nif i == 0:\n print(n)\nelse\n print(n*2)', 'n = int(input())\ni = n % 2\n \nif i == 0:\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s231795059', 's134924899']
[2940.0, 2940.0]
[17.0, 17.0]
[67, 69]
p03307
u492532572
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif N % 2 == 0:\n print(2 * N)\nelse:\n print(N)', 'N = int(input())\nif N % 2 == 0:\n print(N)\nelse:\n print(2 * N)']
['Wrong Answer', 'Accepted']
['s543390022', 's829406676']
[2940.0, 2940.0]
[17.0, 18.0]
[67, 67]
p03307
u497363157
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = input()\naryA = input().split(" ")\n\nN = int(N)\naryA = [int(s) for s in aryA]\nn = len(aryA)\n\ntot = []\ntotlist = []\nb = N\n\nfor m in range(b):\n for x in range(n):\n tot.append(abs(aryA[x] - (m + x + 1)))\n totlist.append(sum(tot))\n\nprint(min(totlist))', 'N = input()\nN = int(N)\ndef gcd(a, b):\n\twhile b:\n\t\ta, b = b, a % b\n\treturn a\n\ndef lcm(x, y):\n return (x * y) // gcd(x, y)\n\nprint(lcm(2, N))']
['Runtime Error', 'Accepted']
['s537231076', 's450677150']
[3064.0, 2940.0]
[18.0, 17.0]
[262, 141]
p03307
u503228842
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif not N%2:\n print(2*N)\nelse:print(N)', 'N = int(input())\nif N%2:\n print(2*N)\nelse:print(N)']
['Wrong Answer', 'Accepted']
['s309265025', 's094617932']
[2940.0, 2940.0]
[17.0, 17.0]
[57, 53]
p03307
u503901534
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\n\nif n % 2 ==0:\n print(n)\nelse:\n print(n + 1)', 'n = int(input())\n\nif n % 2 ==0:\n print(n)\nelse:\n print(n * 2)']
['Wrong Answer', 'Accepted']
['s313172921', 's400348806']
[2940.0, 2940.0]
[17.0, 18.0]
[67, 67]
p03307
u506858457
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N=int(input())\nif N%2==0:\n ans=N\nelse:\n ans=2N\nprint(ans)', 'N=int(input())\nif N%2==0:\n ans=N\nelse:\n ans=2*N\nprint(ans)']
['Runtime Error', 'Accepted']
['s772740158', 's279957082']
[2940.0, 2940.0]
[17.0, 17.0]
[59, 60]
p03307
u510064927
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nA = list(map(int, input().strip().split()))\nmin_n = max_n = A[0]\nfor i in range(1, N):\n\tnum = A[i]\n\tif min_n > num:\n\t\tmin_n = num\n\tif max_n < num:\n\t\tmax_n = num\nresult = max_n - min_n\nprint(result)\n\t\t', 'N = int(input())\nresult = N if N&1==0 else N<<1\nprint(result)']
['Runtime Error', 'Accepted']
['s842234644', 's288642236']
[2940.0, 2940.0]
[17.0, 17.0]
[217, 61]
p03307
u519003353
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=input()\nif n %2==0:\n print(n)\nelse:\n print(2*n)', 'N=int(input())\nif N %2==0:\n print(N)\nelse:\n print(N*2)']
['Runtime Error', 'Accepted']
['s464069378', 's440721357']
[2940.0, 2940.0]
[17.0, 17.0]
[55, 60]
p03307
u525595811
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\n\nif n % 2 == 0:\n print(n*2)\nelse:\n print(n)\n', ' = int(input())\n 2 \n 3 if n % 2 == 0:\n 4 print(n)\n 5 else:\n 6 print(n*2)\n', 'n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(n*2)\n']
['Wrong Answer', 'Runtime Error', 'Accepted']
['s061710889', 's507311161', 's564726542']
[2940.0, 2940.0, 2940.0]
[19.0, 17.0, 17.0]
[67, 86, 67]
p03307
u530844517
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
["n = int(input())\nprint(n) if n%2 == 0 else print('No')", 'n = int(input())\nprint(n) if n%2 == 0 else print(n*2)']
['Wrong Answer', 'Accepted']
['s885680707', 's018217074']
[2940.0, 2940.0]
[18.0, 17.0]
[54, 53]
p03307
u536177854
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nfor i in 10**9:\n if n%2==0 and n%i==0:\n print(i)\n exit()', 'n=int(input())\nif(n%2==0):\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s935740700', 's193148482']
[2940.0, 2940.0]
[17.0, 17.0]
[78, 56]
p03307
u545368057
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['def gcd(n, m):\n \n a = max(n,m)\n b = min(n,m)\n while b:\n a, b = b, a % b\n return a\n\nn = input()\nprint(2*n/gcd(2,n))', 'def gcd(n, m):\n \n a = max(n,m)\n b = min(n,m)\n while b:\n a, b = b, a % b\n return a\n\nn = int(input())\nprint(2*n//gcd(2,n))']
['Runtime Error', 'Accepted']
['s017258728', 's504307631']
[3060.0, 2940.0]
[18.0, 17.0]
[153, 159]
p03307
u546235346
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['x = input()\nif x % 2 == 0:\n\tprint(x)\nelse:\n\tprint(x*2)\n', 'x = int(input())\nif x % 2 == 0:\n\tprint(x)\nelse:\n\tprint(x*2)\n']
['Runtime Error', 'Accepted']
['s476247460', 's679403720']
[2940.0, 2940.0]
[17.0, 17.0]
[55, 60]
p03307
u549566584
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['i = input()\n\nif i % 2 == 0:\n print(i)\nelse:\n print(i*2)', 'i = int(input())\n\nif i % 2 == 0:\n print(i)\nelse:\n print(i*2)']
['Runtime Error', 'Accepted']
['s461463462', 's817418503']
[2940.0, 3064.0]
[17.0, 17.0]
[61, 66]
p03307
u555356625
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\n\nif n%2:\n print(2+n)\nelse:\n print(n)', 'n = int(input())\n\nif n%2:\n print(2*n)\nelse:\n print(n)']
['Wrong Answer', 'Accepted']
['s131319271', 's742446218']
[2940.0, 2940.0]
[17.0, 17.0]
[55, 55]
p03307
u556589653
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = int(input())\nif N%2 = 0:\n print(N)\nelse:\n print(2*N)', 'N = int(input())\nif N%2 == 0:\n print(N)\nelse:\n print(2*N)\n']
['Runtime Error', 'Accepted']
['s280063834', 's015045329']
[2940.0, 2940.0]
[17.0, 18.0]
[58, 60]
p03307
u563379250
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['if n%2==0:\n print(n)\nelse:\n print(n*2)', 'from fractions import gcd\nprint(int(2 * n / gcd(2, n)))', 'n = int(input())\nif n%2==0:\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Runtime Error', 'Accepted']
['s229538704', 's371371188', 's352845401']
[2940.0, 5304.0, 2940.0]
[17.0, 39.0, 18.0]
[40, 55, 57]
p03307
u571444155
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(2*n', 'n = int(input())\n\nif n % 2 == 0:\n print(n)\nelse:\n print(2*n)\n']
['Runtime Error', 'Accepted']
['s272411596', 's213174023']
[2940.0, 2940.0]
[17.0, 17.0]
[61, 63]
p03307
u578489732
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
["# -*- coding: utf-8 -*-\nimport sys\n# ----------------------------------------------------------------\n# Use Solve Function\n\ndef solve(lines):\n N = int(lines.pop(0))\n if N % 2 == 0:\n print(N)\n else:\n print(N*2)\n\n#\n# main\n#\n\n# 1. use list instead of stdin\n\n#contents = '''\\\n#999999999\\\n#'''\n\n\n# 2. use stdin\n\nlines = [x.strip() for x in sys.stdin.readlines()]\n", "# -*- coding: utf-8 -*-\nimport sys\n# ----------------------------------------------------------------\n# Use Solve Function\n\ndef solve(lines):\n N = int(lines.pop(0))\n if N % 2 == 0:\n print(N)\n else:\n print(N*2)\n\n#\n# main\n#\n\n# 1. use list instead of stdin\n\n#contents = '''\\\n#999999999\\\n#'''\n\n\n# 2. use stdin\n\nlines = [x.strip() for x in sys.stdin.readlines()]\n\n#\n# solve !!\n#\nsolve(lines)"]
['Wrong Answer', 'Accepted']
['s986481561', 's423451771']
[3060.0, 3064.0]
[19.0, 18.0]
[410, 438]
p03307
u594762426
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['if a%2 == 0:\n print(a)\nelse:\n print(a*2)', 'a = int(input())\n\nif a % 2 == 0:\n print(a)\nelse:\n print(a*2)']
['Runtime Error', 'Accepted']
['s391031650', 's061042850']
[2940.0, 2940.0]
[17.0, 17.0]
[46, 66]
p03307
u595893956
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['N = input()\nif N%2 == 1:\n N*=2\nprint(N)', 'N=int(input())\nif N%2==1 :\n N*=2\nprint(N)']
['Runtime Error', 'Accepted']
['s322958503', 's042224867']
[2940.0, 2940.0]
[18.0, 18.0]
[40, 42]
p03307
u595952233
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input().split())\nif n % 2 == 0:\n print(n)\nelse:\n print(n*2)', 'n = int(input())\nif n % 2 == 0:\n print(n)\nelse:\n print(n*2)']
['Runtime Error', 'Accepted']
['s660796277', 's225003554']
[9088.0, 9036.0]
[25.0, 25.0]
[69, 61]
p03307
u597374218
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n=int(input())\nprint([N,N*2][N%2])', 'N=int(input())\nprint(N+N%2*N)']
['Runtime Error', 'Accepted']
['s932439169', 's725646847']
[2940.0, 9024.0]
[16.0, 26.0]
[34, 29]
p03307
u597455618
2,000
1,048,576
You are given a positive integer N. Find the minimum positive integer divisible by both 2 and N.
['n = int(input)\nif n%2 == 0:\n print(n)\nelse:\n print(2*n)', 'n = int(input())\nif n%2 == 0:\n print(n)\nelse:\n print(2*n)']
['Runtime Error', 'Accepted']
['s294008385', 's125777397']
[2940.0, 3316.0]
[17.0, 19.0]
[57, 59]