start
stringlengths
5
368
code
stringlengths
5
143
end
stringlengths
5
527
i = 3; m = 7
m = i
i = 3; m = 3
q = [0]; x = 1
q.append(x)
q = [0, 1]; x = 1
d = {(1): 1, (2): 2, (3): 2, (6): 1, (5): 2, (4): 2}; e = 6
d[e] += 1
d = {1: 1, 2: 2, 3: 2, 6: 2, 5: 2, 4: 2}; e = 6
y = 1
y += 1
y = 2
h = True; m = '1000'; o = '100010001'
h = o.find(m) == 0
h = True; m = '1000'; o = '100010001'
l = 'hACKERrANK.COM PRESENTS "pYTHONIS'; x = 't'
l = l + x.upper()
l = 'hACKERrANK.COM PRESENTS "pYTHONIST'; x = 't'
r = 4; s = 5
r = s % 7
r = 5; s = 5
n = [[1, 1]]; q = [1, 1]
n.append(q)
n = [[1, 1], [1, 1]]; q = [1, 1]
i = 1; l = [0]
l.append(i)
i = 1; l = [0, 1]
n = 1
g = n
g = 1; n = 1
i = 2; x = [{'data': 1, 'left': 1, 'right': 2, 'height': 1}, {'data': 2, 'left': 3, 'right': None, 'height': 1}, {'data': 3, 'left': None, 'right': None, 'height': 1}]; y = 5
x[i]['left'] = y - 1
i = 2; x = [{'data': 1, 'left': 1, 'right': 2, 'height': 1}, {'data': 2, 'left': 3, 'right': None, 'height': 1}, {'data': 3, 'left': 4, 'right': None, 'height': 1}]; y = 5
d = {(2): 3}; i = 2
d[i] += 1
d = {2: 4}; i = 2
t = 1836311903; y = [0, 1, 1, 2, 3, 5, 8, 63245986, 102334155, 165580141, 267914296, 433494437, 701408733, 1134903170]
y.append(t)
t = 1836311903; y = [0, 1, 1, 2, 3, 5, 8, 63245986, 102334155, 165580141, 267914296, 433494437, 701408733, 1134903170, 1836311903]
a = [1, 2, 3, 4]; e = -12; i = 2; j = 1; k = 2; u = [[0, inf, inf, inf, inf], [-2, -2, inf, inf, inf], [-6, -2, -6, inf, inf], [-12, 0, inf, inf, inf], [inf, inf, inf, inf, inf]]
e = u[i][j] + a[i] * (j - (k - j))
a = [1, 2, 3, 4]; e = -2; i = 2; j = 1; k = 2; u = [[0, inf, inf, inf, inf], [-2, -2, inf, inf, inf], [-6, -2, -6, inf, inf], [-12, 0, inf, inf, inf], [inf, inf, inf, inf, inf]]
a = 0
a += 1
a = 1
n = 1
n = n // 10
n = 0
i = 32; x = 961
x = i * i
i = 32; x = 1024
w = [[inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf]]
w[0][0] = 0
w = [[0, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf], [inf, inf, inf, inf, inf]]
p = [2, 3, 2, 1]; x = 4; y = 1
p.append(abs(x - y))
p = [2, 3, 2, 1, 3]; x = 4; y = 1
c = 2
c -= 1
c = 1
e = 5
a = e
a = 5; e = 5
n = '148'; p = '148'
p = p + n
n = '148'; p = '148148'
m = []; z = 1
z = len(m)
m = []; z = 0
g = [[], [2, 3, 4, 5, 6, 7], [3, 4, 5, 6, 7, 8], [4, 5, 6, 7, 8], [], [], [ ], [], [], [], [], [], []]; q = 3; z = 9
g[q].append(z)
g = [[], [2, 3, 4, 5, 6, 7], [3, 4, 5, 6, 7, 8], [4, 5, 6, 7, 8, 9], [], [], [], [], [], [], [], [], []]; q = 3; z = 9
e = 0; i = 2
e = i
e = 2; i = 2
c = [1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 2, 2, 1, 2, 1]; x = 1; y = 3
c.append(abs(int(x) - int(y)))
c = [1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 2, 2, 1, 2, 1, 2]; x = 1; y = 3
a = 12
a += 1
a = 13
a = 1; b = 2; c = 3; h = 999
h = max(a, b, c)
a = 1; b = 2; c = 3; h = 3
o = 14
o = o / 2
o = 7.0
g = [140, 0, 7, 1]; w = 0
g[w] += 1
g = [141, 0, 7, 1]; w = 0
b = [1, 3, 1, 2]; d = 4; x = [0, 0, 0, 0]
x[d - 1] = b[d - 1]
b = [1, 3, 1, 2]; d = 4; x = [0, 0, 0, 2]
d = {(0): 1}; i = 0; m = 2
d[i] = m
d = {0: 2}; i = 0; m = 2
c = ['HA', 'HC', 'HK', 'AH', 'AC']; z = 'A', 'K'
c.append(''.join(z))
c = ['HA', 'HC', 'HK', 'AH', 'AC', 'AK']; z = ('A', 'K')
t = '2'; x = 6; z = {'1': 3, '2': 0, '4': 0, '6': 0, '5': 0, '3': 0}
z[t] = z[t] + x
t = '2'; x = 6; z = {'1': 3, '2': 6, '4': 0, '6': 0, '5': 0, '3': 0}
q = '12'
q = int(q)
q = 12
a = 2; b = 10; d = 5242904; i = 19
d += a ^ b << i
a = 2; b = 10; d = 10485786; i = 19
a = ['1', '2', '3', '5', '4']
a = list(map(int, a))
a = [1, 2, 3, 5, 4]
m = [[3, 3, 4, 4, 9], [9, 3, 3]]; o = [9, 3, 3]
m.append(o)
m = [[3, 3, 4, 4, 9], [9, 3, 3], [9, 3, 3]]; o = [9, 3, 3]
f = 7
f += 1
f = 8
e = 'i'; s = {'a': 1, 'e': 1, 'i': 1, 'o': 2, 'u': 2}
s[e] += 1
e = 'i'; s = {'a': 1, 'e': 1, 'i': 2, 'o': 2, 'u': 2}
a = [1, 1, 1, 1, 1, 1]; n = 33554431
a.append(n % 2)
a = [1, 1, 1, 1, 1, 1, 1]; n = 33554431
g = {1, 4}; x = 3
g.add(x * 2)
g = {1, 4, 6}; x = 3
d = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 52, 24}; s = {1, 2, 3, 4, 5, 6, 7, 8, 9, 11}
d &= s
d = {1, 2, 3, 4, 5, 6, 7, 8, 9, 11}; s = {1, 2, 3, 4, 5, 6, 7, 8, 9, 11}
i = 4
i += 1
i = 5
i = 1; k = 0
k = i
i = 1; k = 1
j = 3; m = 7; u = [0, 3]
u.append((j + u[-1]) % m)
j = 3; m = 7; u = [0, 3, 6]
g = [29, 0, 0, 0]; w = 0
g[w] += 1
g = [30, 0, 0, 0]; w = 0
b = 'X_Y__X'; d = {'R': 2, 'B': 2, 'Y': 2, '_': 1}; i = 0
d[b[i]] = 1
b = 'X_Y__X'; d = {'R': 2, 'B': 2, 'Y': 2, '_': 1, 'X': 1}; i = 0
a = 2
x[a] = 1
a = 2; x = {2: 1}
e = 3; l = 1; r = 2
c.append([e, l, r])
c = [[3, 1, 2]]; e = 3; l = 1; r = 2
i = [['Q', '1']]; s = ['M', '1', '2']
i.append(s)
i = [['Q', '1'], ['M', '1', '2']]; s = ['M', '1', '2']
q = 1
q -= 1
q = 0
i = 3; p = [1, 2]
p.append(i)
i = 3; p = [1, 2, 3]
i = 5; j = 200; n = [0, 100, 100, 0, 0, -100]
j += n[i]
i = 5; j = 100; n = [0, 100, 100, 0, 0, -100]
d = 4; i = 1; n = [1, 2, 3, 4]; o = [1, 2, 3, 4, 10, 20, 30, 40, 100, 200]
n = o[i:i + d]
d = 4; i = 1; n = [2, 3, 4, 10]; o = [1, 2, 3, 4, 10, 20, 30, 40, 100, 200]
b = '1'; t = ['1', '0', '0', '0', '0', '0', '0', '0', '0']
t.append('0' if b == '1' else '1')
b = '1'; t = ['1', '0', '0', '0', '0', '0', '0', '0', '0', '0']
n = ['2', '5']
u = int(n[0])
n = ['2', '5']; u = 2
c = 3; p = 5
c = p
c = 5; p = 5
c = '3'; d = 2
d = int(c)
c = '3'; d = 3
c = 12
c += 1
c = 13
n = 1.2; s = 2
s += n % 10
n = 1.2; s = 3.2
k = 122; m = [22, 79, 21]
k = int(m[0])
k = 22; m = [22, 79, 21]
a = '1 2 100\n'
a = [int(x) for x in a.split()]
a = [1, 2, 100]
l = ['{', '{', '[', '[', '(', '(']
l.pop()
l = ['{', '{', '[', '[', '(']
f = 2
f = f + 1
f = 3
i = 0; o = [3, 3]; r = 98
r += pow(i + 1, o[1])
i = 0; o = [3, 3]; r = 99.0
i = 0
i = i + 2
i = 2
s = 2.0; v = 2
s += v * (v - 1) / 2
s = 3.0; v = 2
c = 89; z = 144
z = c + z
c = 89; z = 233
a = [-20, -3916237, -357920, -3620601, 7374819, -7330761, 30, 6246457, - 6461594, 266854, -520, -470]
a.sort()
a = [-7330761, -6461594, -3916237, -3620601, -357920, -520, -470, -20, 30, 266854, 6246457, 7374819]
a = [[1], [1, 1], [1, 2, 1]]; r = [1, 3, 3, 1]
a.append(r)
a = [[1], [1, 1], [1, 2, 1], [1, 3, 3, 1]]; r = [1, 3, 3, 1]
k = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
k = k + [0]
k = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
h = 4; v = {1, 2, 3, 4, 6}; z = 2
v.add(z * h)
h = 4; v = {1, 2, 3, 4, 6, 8}; z = 2
d = ['3', 'be', False]; u = [['0', 'ab', True], ['6', 'cd', True], ['0', 'ef', True], ['6', 'gh', True], ['0', 'ij', True], ['4', 'that', False]]
u.append(d)
d = ['3', 'be', False]; u = [['0', 'ab', True], ['6', 'cd', True], ['0', 'ef', True], ['6', 'gh', True], ['0', 'ij', True], ['4', 'that', False], ['3', 'be', False]]
x = 73786976294838206464
x *= 2
x = 147573952589676412928
c = 18; f = 3.0
f -= c
c = 18; f = -15.0
a = 50; b = 60; i = 5; q = [-10000000000, 30, 38, 48, 50, 60, 10000000000]
a, b = q[i], q[i + 1]
a = 60; b = 10000000000; i = 5; q = [-10000000000, 30, 38, 48, 50, 60, 10000000000]
c = 'gurwgrb'; i = 2; o = 'gu'
o = c[:i + 1]
c = 'gurwgrb'; i = 2; o = 'gur'
l = 3.3333333333333335; t = 2
t *= l
l = 3.3333333333333335; t = 6.666666666666667
d = [(10000000, -1), (10000000, -1), (10000000, -1), (2, 0)]
d[nn], d[nn + 1] = d[nn + 1], d[nn]
d = [(10000000, -1), (10000000, -1), (10000000, -1), (2, 0)]; y = True
n = 4; r = 1.8
r += n / 2
n = 4; r = 3.8
c = 6; g = [[1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4]]; m = 3; n = 6; y = 0
y = g[m][n - c] if n - c >= 0 else 0
c = 6; g = [[1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4], [1, 0, 1, 3, 3, 4]]; m = 3; n = 6; y = 1
e = [2]; n = 3
e.append(n)
e = [2, 3]; n = 3
c = 'o'; p = 'aeiouuoiea'; v = 4
c = p[v]
c = 'u'; p = 'aeiouuoiea'; v = 4
w = '100002'; x = 100003
w = str(x)
w = '100003'; x = 100003
g = '10 2 '
f = g.split()
f = ['10', '2']; g = '10 2 '
j = {'a': 0, 'b': 0, 'c': 1}; v = 'c'
j[v] += 1
j = {'a': 0, 'b': 0, 'c': 2}; v = 'c'
i = 'judged'; m = ['p', 'r', 'o', 'm', 'p', 't', 'l', 'y']
m = list(i)
i = 'judged'; m = ['j', 'u', 'd', 'g', 'e', 'd']
a = 1
d[a] = 1
a = 1; d = {1: 1}
i = 0; j = 1; r = [['+', '-', '+', '+', '+', '+'], ['+', '-', '+', '+', '+', '+'], ['+', '-', '-', '-', '+', '+'], ['+', '+', '+', '+', '+', '+'], ['+', '+', '+', '+', '+', '+'], ['+', '+', '+', '+', '+', '+']]
w = r[i][j]
i = 0; j = 1; r = [['+', '-', '+', '+', '+', '+'], ['+', '-', '+', '+', '+', '+'], ['+', '-', '-', '-', '+', '+'], ['+', '+', '+', '+', '+', '+'], ['+', '+', '+', '+', '+', '+'], ['+', '+', '+', '+', '+', '+']]; w = '-'
n = ['a', 'f']; z = 97, 103
n = list(map(chr, z))
n = ['a', 'g']; z = (97, 103)
b = 3; p = 4
b = p
b = 4; p = 4
i = 4; q = [1, 2, 3, 5, 4]; w = 3
q[w] = i
i = 4; q = [1, 2, 3, 4, 4]; w = 3
a = 146; b = [99, 123, 138, 155, 174, 114, 138, 153, 170, 189, 114, 129, 146, 165, 105, 129, 144, 161, 180, 122]; m = 1000
b.append(a % m)
a = 146; b = [99, 123, 138, 155, 174, 114, 138, 153, 170, 189, 114, 129, 146, 165, 105, 129, 144, 161, 180, 122, 146]; m = 1000
d = OrderedDict([('BANANA FRIES', 12), ('POTATO CHIPS', 30), ('APPLE JUICE', 20), ('CANDY', 20)]); n = 'POTATO CHIPS'; q = 30
d[n] += q
d = OrderedDict([('BANANA FRIES', 12), ('POTATO CHIPS', 60), ('APPLE JUICE', 20), ('CANDY', 20)]); n = 'POTATO CHIPS'; q = 30
b = 21; u = [2, 3, 4, 5, 6, 7, 12, 13, 14, 15, 16, 17, 18, 19, 20]
u.append(b)
b = 21; u = [2, 3, 4, 5, 6, 7, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21]
a = {(0): 0, (1): 1, (2): 2, (3): 3, (4): 3}; c = 3; k = 3
a[c * k] = a[c] + 1
a = {0: 0, 1: 1, 2: 2, 3: 3, 4: 3, 9: 4}; c = 3; k = 3
a = 'hi'; d = {'h': 1}; i = 1
d[a[i]] = 1
a = 'hi'; d = {'h': 1, 'i': 1}; i = 1
c = 2; p = [6, 5, 8, 4, 7, 10, 9]
del p[c - dels]
b = True; c = 2; p = [6, 8, 4, 7, 10, 9]
a = 3; t = 1
a = t
a = 1; t = 1