start stringlengths 5 368 | code stringlengths 5 143 | end stringlengths 5 527 |
|---|---|---|
i = 0; j = 4; r = [97, 102, 105]; s = 'ifailuhkqq' | r = [ord(x) for x in s[i:i + j]] | i = 0; j = 4; r = [105, 102, 97, 105]; s = 'ifailuhkqq' |
e = 'b'; x = ['b'] | x.append(e) | e = 'b'; x = ['b', 'b'] |
m = 3; x = 6 | e = float(m) / float(x) | e = 0.5; m = 3; x = 6 |
x = 4 | x = bin(x)[2:] | x = '100' |
u = 'hA'; x = 'c' | u = u + x.upper() | u = 'hAC'; x = 'c' |
a = [1, 3, 3, 3]; i = 2; j = 1; k = 1; m = -7; u = [[0, inf, inf, inf, inf], [-1, -3, inf, inf, inf], [-4, -4, -12, inf, inf], [-7, -1, inf, inf, inf], [inf, inf, inf, inf, inf]] | m = u[i][j] + a[i] * (j - (k - j)) | a = [1, 3, 3, 3]; i = 2; j = 1; k = 1; m = -1; u = [[0, inf, inf, inf, inf], [-1, -3, inf, inf, inf], [-4, -4, -12, inf, inf], [-7, -1, inf, inf, inf], [inf, inf, inf, inf, inf]] |
r = [[2, 1], [3, 0], [0, 3], [2, 1], [], []]; s = 2; u = 3 | r[s - 1].append(u - 1) | r = [[2, 1], [3, 0, 2], [0, 3], [2, 1], [], []]; s = 2; u = 3 |
d = 5; i = 1; n = [0, 999, 0, 0, 0, 0]; q = [0, 1, 1, 1, 999]; z = 2 | z = max(z, q[i] + q[i + 1] + q[i + 2] + n[min(i + 3, d)]) | d = 5; i = 1; n = [0, 999, 0, 0, 0, 0]; q = [0, 1, 1, 1, 999]; z = 3 |
c = '{'; t = ['{', '[', '('] | t.append(c) | c = '{'; t = ['{', '[', '(', '{'] |
j = 0 | j = j + 1 | j = 1 |
r = 1; x = 0 | r += 2 ** x | r = 2; x = 0 |
s = [1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2]; x = 1; y = 2 | s.append(abs(x - y)) | s = [1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2, 1]; x = 1; y = 2 |
i = 7; y = [1, 2, 1, 2, 1, 2, 3, 1, 1, 1] | y[i] = y[i - 1] + 1 | i = 7; y = [1, 2, 1, 2, 1, 2, 3, 4, 1, 1] |
m = [inf, 1, 0, 2] | w = len(m) - 1 | m = [inf, 1, 0, 2]; w = 3 |
i = 2; j = ['lmon', 'no answer', 'dcbb', 'abdc', 'abcd', 'fedcbabcd']; u = ['d', 'c', 'b', 'a'] | u = list(j[i]) | i = 2; j = ['lmon', 'no answer', 'dcbb', 'abdc', 'abcd', 'fedcbabcd']; u = ['d', 'c', 'b', 'b'] |
i = 'ab' | s = list(i) | i = 'ab'; s = ['a', 'b'] |
k = 12; r = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l'] | r.append(chr(ord('a') + k)) | k = 12; r = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm'] |
d = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] | d = d + [0] | d = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] |
n = '15'; w = '15' | w, n = int(w), int(n) | n = 15; w = 15 |
x = '11111111111111111' | x = x + '1' | x = '111111111111111111' |
i = 2; j = 2; y = deque([]) | y.append([i, j - 1, 1, i, j]) | i = 2; j = 2; y = deque([[2, 1, 1, 2, 2]]) |
y = deque([3, 2, 1, 3]) | y.popleft() | y = deque([2, 1, 3]) |
h = 9 | g = h | g = 9; h = 9 |
n = '2 3\n' | n = [int(i) for i in n.split()] | n = [2, 3] |
b = 'QQQ' | b = b.replace(b[0], '') | b = '' |
i = 3; j = 2 | j += i // 2 | i = 3; j = 3 |
i = 1; j = 2; x = 'abc'; y = ['a', 'ab', 'abc'] | y.append(x[i:j]) | i = 1; j = 2; x = 'abc'; y = ['a', 'ab', 'abc', 'b'] |
b = 2; k = 3 | b = k if k > b else b | b = 3; k = 3 |
g = [72, 0, 0, 0]; w = 0 | g[w] += 1 | g = [73, 0, 0, 0]; w = 0 |
a = [[], [], [], []]; t = 2; v = 1 | a[v].append(t) | a = [[], [2], [], []]; t = 2; v = 1 |
r = 0.3010299956639812; s = 9 | p = s * r % 1 | p = 0.7092699609758308; r = 0.3010299956639812; s = 9 |
l = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] | l = l + [0] | l = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] |
c = 2; s = 0; x = 0 | h = (x ^ s) % c | c = 2; h = 0; s = 0; x = 0 |
x = '1' | s = int(x) | s = 1; x = '1' |
g = [5, 2, 1, 8] | g.sort() | g = [1, 2, 5, 8] |
p = 0; q = [0, 0, 0, 0, 0, 0]; t = 'babab' | q[p] = len(t) | p = 0; q = [5, 0, 0, 0, 0, 0]; t = 'babab' |
i = 0; k = [3, 2, 1] | z = z + k[i] | i = 0; k = [3, 2, 1]; z = 12 |
z = 9 | z = z / 2 | z = 4.5 |
p = 4; s = [3] | p = s[0] | p = 3; s = [3] |
t = [5]; y = [[3], [1, 2, 5], [1, 2, 5], [1, 2, 5], [2, 5], [2, 5]] | y.append(t) | t = [5]; y = [[3], [1, 2, 5], [1, 2, 5], [1, 2, 5], [2, 5], [2, 5], [5]] |
b = 2; s = [2, 3, 4] | s.remove(b) | b = 2; s = [3, 4] |
w = [2, 4, 11, 12] | v = set(w) | v = {2, 11, 4, 12}; w = [2, 4, 11, 12] |
t = 64 | t *= 2 | t = 128 |
i = 0; n = [(9.0, 2), (19.0, 4), (75.0, 3), (89.0, 5), (91.0, 1)] | x.append(n[i][1]) | i = 0; n = [(9.0, 2), (19.0, 4), (75.0, 3), (89.0, 5), (91.0, 1)]; x = [2] |
d = set(); y = 140693569796016, 140694031934720; z = array([1.5, 3.5]) | d.add(y) | d = {(140693569796016, 140694031934720)}; y = (140693569796016, 140694031934720); z = array([1.5, 3.5]) |
i = '\n'; s = ['10101', '11100', '11010', '00101', ''] | s.append(i.strip()) | i = '\n'; s = ['10101', '11100', '11010', '00101', '', ''] |
a = 'X'; y = {'R': 2, 'B': 2, 'Y': 2} | y[a] = 1 | a = 'X'; y = {'R': 2, 'B': 2, 'Y': 2, 'X': 1} |
c = [[1, 3, 1], [2, 1, 2], [3, 3, 3]]; n = 3 | n = len(c) | c = [[1, 3, 1], [2, 1, 2], [3, 3, 3]]; n = 3 |
j = 1; o = 3; q = [1, 4, 4, 5, 6, 2] | q[j] = o | j = 1; o = 3; q = [1, 3, 4, 5, 6, 2] |
a = 2; f = [(3, 2), (5, 0), (10, 1)]; i = 3; n = 2 | i, a = f[n - 1] | a = 0; f = [(3, 2), (5, 0), (10, 1)]; i = 5; n = 2 |
i = 1; s = ['1']; u = ['x**3', '+', 'x**2', '+', 'x', '+', '1'] | s.append(u[i]) | i = 1; s = ['1', '+']; u = ['x**3', '+', 'x**2', '+', 'x', '+', '1'] |
k = ['a', 'aa', 'aaa', 'aaaa', 'aaaaa', 'aaaaaa', 'aaaaaaa', 'aaaaaaaa', 'aaaaaaaaa', 'aaaaaaaaaa']; o = 3; y = ['gurwgrb'] | y.append(k[o]) | k = ['a', 'aa', 'aaa', 'aaaa', 'aaaaa', 'aaaaaa', 'aaaaaaa', 'aaaaaaaa', 'aaaaaaaaa', 'aaaaaaaaaa']; o = 3; y = ['gurwgrb', 'aaaa'] |
c = 2; d = 99 | d = c + 1 | c = 2; d = 3 |
i = 1; k = [2, 3, 4, 5]; m = {} | m = {i: (0) for i in k} | i = 1; k = [2, 3, 4, 5]; m = {2: 0, 3: 0, 4: 0, 5: 0} |
a = [34, 21, 21, 13]; b = [34, 21, 21, 13]; f = 1000000007; p = [1597, 0, 0, 0] | p[1] = (a[0] * b[1] + a[1] * b[3]) % f | a = [34, 21, 21, 13]; b = [34, 21, 21, 13]; f = 1000000007; p = [1597, 987, 0, 0] |
u = 2; x = 0; z = 1 | z = (x ^ lastans) % u | q = 52; u = 2; x = 0; z = 0 |
i = 1; n = 1; s = 'cdcd'; v = ['c'] | v.append(s[i:i + n]) | i = 1; n = 1; s = 'cdcd'; v = ['c', 'd'] |
b = 96 | b = b - 3 | b = 93 |
i = 'Y'; p = ['R', 'B', 'Y'] | p.remove(i) | i = 'Y'; p = ['R', 'B'] |
l = [0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; p = (0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) | p = tuple(l) | l = [0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; p = (0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) |
j = 1; o = 2; r = ['e', 'd', 'c', 'd', 'e']; v = ['e', 'd', 'c', 'b', 'a'] | r.append(v[o - abs(j - o) - 1]) | j = 1; o = 2; r = ['e', 'd', 'c', 'd', 'e', 'e']; v = ['e', 'd', 'c', 'b', 'a'] |
i = 0; o = 4 | o = i | i = 0; o = 0 |
i = 2.9103830456733704e-10; q = 1.4551915228366852e-10 | i = q % 2 | i = 1.4551915228366852e-10; q = 1.4551915228366852e-10 |
a = 3 | i.append(a) | a = 3; i = [3] |
j = False; o = '11111111111111111111111111111111' | j = int(o, 2) | j = 4294967295; o = '11111111111111111111111111111111' |
b = 5; c = 2; j = {(1): 1, (5): 1, (3): 1} | c -= j.get(b, 0) | b = 5; c = 1; j = {1: 1, 5: 1, 3: 1} |
d = {'a': 2, 'b': 2}; e = 'a' | z = z + d[e] * (d[e] - 1) / 2 | d = {'a': 2, 'b': 2}; e = 'a'; z = -62.0 |
p = [5, 3, 3, 2] | p = [0] * 4 | p = [0, 0, 0, 0] |
l = [] | i = [list(k) for k in l] | i = []; l = [] |
b = {'a': 1, 'b': 1, 'c': 1, 'd': 1}; c = 'e' | b[c] = 1 | b = {'a': 1, 'b': 1, 'c': 1, 'd': 1, 'e': 1}; c = 'e' |
v = 'AB'; x = 'C' | v = v + x | v = 'ABC'; x = 'C' |
l = [1, 2, 3, 4, 5, 6, 7, 8]; x = [2, 3, 4, 1, 5, 6, 7, 8] | l = x | l = [2, 3, 4, 1, 5, 6, 7, 8]; x = [2, 3, 4, 1, 5, 6, 7, 8] |
a = 5; s = 2; v = 'BANANA' | a = len(v) - s | a = 4; s = 2; v = 'BANANA' |
a = [-7330761, -6461594, -3916237, -3620601, -357920, -20, 30, 266854, 6246457, 7374819]; i = 7; t = 50 | t = a[i] - a[i - 1] | a = [-7330761, -6461594, -3916237, -3620601, -357920, -20, 30, 266854, 6246457, 7374819]; i = 7; t = 266824 |
q = [5, 8]; u = 9 | q.append(u) | q = [5, 8, 9]; u = 9 |
i = ['zfzahm']; x = 'gurwgrb' | i.append(x) | i = ['zfzahm', 'gurwgrb']; x = 'gurwgrb' |
s = [0, 1, 1, 1, 999]; w = [None, None, None, None, None] | w[0] = s[0] | s = [0, 1, 1, 1, 999]; w = [0, None, None, None, None] |
r = """3\n5 8 14\n4 9\n\n\n\n""" | r, a = None, float('-inf') | a = -inf; r = None |
i = 3; u = [1, 12, 66]; y = [1, 11, 55, 165, 330, 462, 462, 330, 165, 55, 11, 1] | u += [(y[i - 1] + y[i]) % 10 ** 9] | i = 3; u = [1, 12, 66, 220]; y = [1, 11, 55, 165, 330, 462, 462, 330, 165, 55, 11, 1] |
i = 2; s = [3, 4, 7, 6, 5] | r.append(s[-i]) | i = 2; r = [6]; s = [3, 4, 7, 6, 5] |
e = 88.0; i = 96.0 | i = e | e = 88.0; i = 88.0 |
f = [1, 1, 4, 9, 16, 25, 36, 49, 64, 81, 3249, 3364, 3481, 3600, 3721, 3844, 3969, 4096, 4225, 4356]; u = 67 | f += [u ** 2] | f = [1, 1, 4, 9, 16, 25, 36, 49, 64, 81, 3249, 3364, 3481, 3600, 3721, 3844, 3969, 4096, 4225, 4356, 4489]; u = 67 |
q = [0, 1, 1, 2, 3, 5, 8, 13, 21]; t = 34 | q.append(t) | q = [0, 1, 1, 2, 3, 5, 8, 13, 21, 34]; t = 34 |
q = 6 | q += 1 | q = 7 |
i = 0; j = 3; s = ['c', 'd', 'c', 'd']; v = ['c', 'd'] | v = s[i:i + j] | i = 0; j = 3; s = ['c', 'd', 'c', 'd']; v = ['c', 'd', 'c'] |
a = [1]; x = 3 | a.append(x) | a = [1, 3]; x = 3 |
m = [75.0, 77.0, 79.0, 81.0, 83.0] | u = sorted(m) | m = [75.0, 77.0, 79.0, 81.0, 83.0]; u = [75.0, 77.0, 79.0, 81.0, 83.0] |
a = '12'; i = 3 | a = a + str(i) | a = '123'; i = 3 |
c = [-7330761, -6461594, -3916237, -3620601, -357920, -520, -470, -20, 30, 266854, 6246457, 7374819]; i = 5; z = [-3916237, -3620601] | z = [c[i], c[i + 1]] | c = [-7330761, -6461594, -3916237, -3620601, -357920, -520, -470, -20, 30, 266854, 6246457, 7374819]; i = 5; z = [-520, -470] |
d = 1; s = 4 | s += d | d = 1; s = 5 |
i = 0; k = 50; u = [1, 5, 10, 12, 111, 200, 1000] | k -= u[i] | i = 0; k = 49; u = [1, 5, 10, 12, 111, 200, 1000] |
b = '1'; s = '111111111111111111111111' | s += b | b = '1'; s = '1111111111111111111111111' |
m = 'night'; r = {'give': 1, 'me': 1, 'one': 1, 'grand': 1, 'today': 1} | r[m] = 0 | m = 'night'; r = {'give': 1, 'me': 1, 'one': 1, 'grand': 1, 'today': 1, 'night': 0} |
j = 'okffng-Q'; z = 119 | j = j + chr(z) | j = 'okffng-Qw'; z = 119 |
i = 2; q = 0 | q = i | i = 2; q = 2 |
c = {(10): 4, (20): 3, (30): 1, (50): 1}; k = 30; s = 3.5 | s += c[k] / 2 | c = {10: 4, 20: 3, 30: 1, 50: 1}; k = 30; s = 4.0 |
i = 0; l = [1, 2, 3, 4, 10, 20, 30, 40, 100, 200, 0]; n = [1] | n.append(n[i] + l[i + 1]) | i = 0; l = [1, 2, 3, 4, 10, 20, 30, 40, 100, 200, 0]; n = [1, 3] |
p = '('; v = ['{', '{', '[', '[', '('] | p = v.pop() | p = '('; v = ['{', '{', '[', '['] |
b = '1'; z = ['1', '0'] | z.append(b) | b = '1'; z = ['1', '0', '1'] |
a = '(?<=[a-zA-Z0-9])([^a-zA-Z0-9]+)(?=[a-zA-Z0-9])'; p = '(?<=[a-zA-Z0-9])([^a-zA-Z0-9]+)(?=[a-zA-Z0-9])' | a = p | a = '(?<=[a-zA-Z0-9])([^a-zA-Z0-9]+)(?=[a-zA-Z0-9])'; p = '(?<=[a-zA-Z0-9])([^a-zA-Z0-9]+)(?=[a-zA-Z0-9])' |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.