s_id
string
p_id
string
u_id
string
date
string
language
string
original_language
string
filename_ext
string
status
string
cpu_time
string
memory
string
code_size
string
code
string
error
string
stdout
string
s310823786
p02235
u970436839
1453257693
Python
Python
py
Runtime Error
0
0
363
def lcs_size(): X = input() Y = input() a = len(X) b = len(Y) z2 = [0 for in range(b+1)] maxl = 0 for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] maxl = max(maxl, z2[j+1]) return maxl q = input() for i in range(q): print lcs_siz()
File "/tmp/tmp198l1a7s/tmpjziig72c.py", line 8 z2 = [0 for in range(b+1)] ^^ SyntaxError: invalid syntax
s645569844
p02235
u630265299
1453257706
Python
Python
py
Runtime Error
0
0
414
def LCS(Xs, Ys): Xs = raw_input() Ys = raw_input() dp = {} count = 0 a = 1 for i in range(len(Ys) + 1): dp[0][i + 1] = Ys[i] for j in range(len(Xs) + 1): dp[j + 1][0] = Xs[j] for i in range(a, len(Ys) + 1): for j in range(a, len(Xs) + 1): if dp[j][0] == dp[i][1]: count = count + 1 a = j break if dp[j][0] == dp[i][1]: break print count
File "/tmp/tmpe53xwzp_/tmppzijgfdb.py", line 22 print count ^ IndentationError: unindent does not match any outer indentation level
s460986431
p02235
u970436839
1453257776
Python
Python
py
Runtime Error
0
0
322
def lcs_size(): X = input() Y = input() a = len(X) b = len(Y) z2 = [0 for in range(b+1)] for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] return z2[-1] q = input() for i in range(q): print lcs_siz()
File "/tmp/tmpgptdyow2/tmp67kpyd6b.py", line 8 z2 = [0 for in range(b+1)] ^^ SyntaxError: invalid syntax
s322688667
p02235
u970436839
1453257830
Python
Python
py
Runtime Error
0
0
330
def lcs_size(): X = raw_input() Y = raw_input() a = len(X) b = len(Y) z2 = [0 for in range(b+1)] for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] return z2[-1] q = input() for i in range(q): print lcs_siz()
File "/tmp/tmpmqa43_gr/tmps4dimf36.py", line 8 z2 = [0 for in range(b+1)] ^^ SyntaxError: invalid syntax
s668038856
p02235
u630265299
1453257834
Python
Python
py
Runtime Error
0
0
401
Xs = raw_input() Ys = raw_input() dp = {} count = 0 a = 1 for i in range(len(Ys) + 1): dp[0][i + 1] = Ys[i] for j in range(len(Xs) + 1): dp[j + 1][0] = Xs[j] for i in range(1, len(Ys) + 1): for j in range(a + 1, len(Xs) + 1): if dp[j][0] == dp[i][1]: count = count + 1 a = j break if dp[j][0] == dp[i][1]: break print count
File "/tmp/tmpszx57olb/tmpnohv8y0x.py", line 1 Xs = raw_input() IndentationError: unexpected indent
s522237907
p02235
u630265299
1453257888
Python
Python
py
Runtime Error
0
0
391
Xs = raw_input() Ys = raw_input() count = 0 a = 1 for i in range(len(Ys) + 1): dp[0][i + 1] = Ys[i] for j in range(len(Xs) + 1): dp[j + 1][0] = Xs[j] for i in range(1, len(Ys) + 1): for j in range(a + 1, len(Xs) + 1): if dp[j][0] == dp[i][1]: count = count + 1 a = j break if dp[j][0] == dp[i][1]: break print count
File "/tmp/tmpau7pbkqz/tmpatmwun6a.py", line 1 Xs = raw_input() IndentationError: unexpected indent
s520914721
p02235
u970436839
1453257969
Python
Python
py
Runtime Error
0
0
347
def lcs_size(): X = raw_input() Y = raw_input() a = len(X) b = len(Y) z2 = [0 for in range(b+1)] for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 elif z2[j+1] < z2[j]: z2[j+1] = z2[j] return z2[-1] q = input() for i in range(q): print lcs_siz()
File "/tmp/tmpdif9j8dk/tmpuzimaifp.py", line 8 z2 = [0 for in range(b+1)] ^^ SyntaxError: invalid syntax
s997938013
p02235
u630265299
1453257973
Python
Python
py
Runtime Error
0
0
391
Xs = raw_input() Ys = raw_input() count = 0 a = 0 for j in range(len(Ys) + 1): dp[0][j + 1] = Ys[i] for i in range(len(Xs) + 1): dp[i + 1][0] = Xs[j] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[j][1]: count = count + 1 a = j break if dp[j][0] == dp[i][1]: break print count
File "/tmp/tmpelbduzge/tmp9q_sqtj_.py", line 1 Xs = raw_input() IndentationError: unexpected indent
s562947385
p02235
u970436839
1453258005
Python
Python
py
Runtime Error
0
0
349
def lcs_size(): X = raw_input() Y = raw_input() a = len(X) b = len(Y) z2 = [0 for i in range(b+1)] for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 elif z2[j+1] < z2[j]: z2[j+1] = z2[j] return z2[-1] q = input() for i in range(q): print lcs_siz()
File "/tmp/tmpjl35h400/tmp13a9gttn.py", line 22 print lcs_siz() ^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s500048790
p02235
u630265299
1453258056
Python
Python
py
Runtime Error
0
0
383
Xs = raw_input() Ys = raw_input() count = 0 a = 0 for j in range(len(Ys) + 1): dp[1][j] = Ys[j] for i in range(len(Xs) + 1): dp[i][1] = Xs[i] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[j][1]: count = count + 1 a = j break if dp[j][0] == dp[i][1]: break print count
File "/tmp/tmpshp6hnmi/tmp0hdcrx0t.py", line 1 Xs = raw_input() IndentationError: unexpected indent
s182544561
p02235
u233232390
1453258130
Python
Python
py
Runtime Error
0
0
342
def solve(): seq1 = raw_input() seq2 = raw_input() a, b = len(seq1), len(seq2) x1 = [0 for i in range(b+1)] for i in range(a): e1 = seq1[i] x2 = x1+[] for j in range(b): if e1 == seq2[j]: x1[j+1] = x2[j] + 1 elif x1[j+1]<x1[j]: x1[j+1] = x1[j] return x1[-1] n = input() for i2 in range(n): print solve()
File "/tmp/tmpao39pjuj/tmpeg8_ogej.py", line 6 for i in range(a): IndentationError: unexpected indent
s561935543
p02235
u630265299
1453258349
Python
Python
py
Runtime Error
0
0
353
Xs = raw_input() Ys = raw_input() count = 0 a = 0 for j in range(len(Ys) + 1): dp[0][j + 1] = Ys[j] for i in range(len(Xs) + 1): dp[i + 1][0] = Xs[i] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[0][j]: count = count + 1 a = i break print count
File "/tmp/tmp8jn544l2/tmpzudmbzss.py", line 1 Xs = raw_input() IndentationError: unexpected indent
s253080472
p02235
u630265299
1453258564
Python
Python
py
Runtime Error
0
0
383
n = input() for i in range(n) Xs = raw_input() Ys = raw_input() count = 0 a = 0 for j in range(len(Ys) + 1): dp[0][j + 1] = Ys[j] for i in range(len(Xs) + 1): dp[i + 1][0] = Xs[i] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[0][j]: count = count + 1 a = i break print count
File "/tmp/tmp2b8ick21/tmped5p74d2.py", line 2 for i in range(n) ^ SyntaxError: expected ':'
s728817614
p02235
u630265299
1453258639
Python
Python
py
Runtime Error
0
0
393
n = input() for i in range(n) Xs = raw_input() Ys = raw_input() count = 0 a = 0 dp = {} for j in range(len(Ys) + 1): dp[0][j + 1] = Ys[j] for i in range(len(Xs) + 1): dp[i + 1][0] = Xs[i] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[0][j]: count = count + 1 a = i break print count
File "/tmp/tmp8j7kjshr/tmp8udsrca7.py", line 2 for i in range(n) ^ SyntaxError: expected ':'
s604566571
p02235
u630265299
1453258676
Python
Python
py
Runtime Error
0
0
393
n = input() for i in range(n) Xs = raw_input() Ys = raw_input() count = 0 a = 0 dp = {} for j in range(len(Ys) + 1): dp[0][j + 1] = Ys[j] for i in range(len(Xs) + 1): dp[i + 1][0] = Xs[i] for j in range(1, len(Ys) + 1): for i in range(a + 1, len(Xs) + 1): if dp[i][0] == dp[0][j]: count = count + 1 a = i break print count
File "/tmp/tmpybzabzab/tmp2m1v0p_q.py", line 2 for i in range(n) ^ SyntaxError: expected ':'
s351958308
p02235
u177808190
1453258826
Python
Python
py
Runtime Error
0
0
407
def lcs(X, Y): X = " " + X Y = " " + Y c = [] for i in X: for j in Y: if X[i] == Y[j]: c[i][j] = c[i - 1][j - 1] + 1 else: c[i][j] = max(c[i - 1][j], c[i][j - 1]) maxl = max(maxl, c[i][j]) n = int(raw_input()) for i in range(n): s1 = raw_input() s2 = raw_input() print lcs(s1, s2)
File "/tmp/tmpu4dncbv5/tmpi19wmq_f.py", line 17 print lcs(s1, s2) ^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s212830914
p02235
u731976921
1453259991
Python
Python
py
Runtime Error
0
0
448
def lcs(s, t): slen = len(s) tlen = len(t) dp = [None] * (slen + 1) for i in range(slen + 1): dp[i] = [0] * (tlen + 1) for i in range(1, slen + 1): for j in range(1, tlen + 1): if s[i-1] == t[j-1]: dp[i][j] = dp[i-1][j-1] + 1 else: dp[i][j] = max(dp[i][j-1], dp[i-1][j]) return dp[slen][tlen] n = int(raw_input()) for i in range(max(n, 20)): x = raw_input() y = raw_input() print lcs(x, y)
File "/tmp/tmphkg45uua/tmpgkequ4et.py", line 23 print lcs(x, y) ^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s383224304
p02235
u253463900
1453285635
Python
Python3
py
Runtime Error
0
0
581
n = int(input()) dataset = [] for i in range(n): tmp = [] tmp.append(input()) tmp.append(input()) dataset.append(tmp) for data in dataset: m = len(data[0]) n = len(data[1]) dp = [] for x in range(n+1): dp.append([0] *(m+1)) for j in range(n): for i in range(m): if data[0][i] == data[1][j]: dp[j+1][i+1] = dp[j][i] + 1 else: #dp[j+1][i+1] = max(dp[j+1][i], dp[j][i+1]) dp[J+1][i+1] = dp[j+1][i] if dp[j+1][i]>dp[j][i+1] else dp[j][i+1] print(dp[n][m])
Traceback (most recent call last): File "/tmp/tmp4ojrupog/tmp4o6arcri.py", line 1, in <module> n = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s194152904
p02235
u253463900
1453285722
Python
Python3
py
Runtime Error
0
0
581
n = int(input()) dataset = [] for i in range(n): tmp = [] tmp.append(input()) tmp.append(input()) dataset.append(tmp) for data in dataset: m = len(data[0]) n = len(data[1]) dp = [] for x in range(n+1): dp.append([0] *(m+1)) for j in range(n): for i in range(m): if data[0][i] == data[1][j]: dp[j+1][i+1] = dp[j][i] + 1 else: #dp[j+1][i+1] = max(dp[j+1][i], dp[j][i+1]) dp[J+1][i+1] = dp[j+1][i] if dp[j+1][i]>dp[j][i+1] else dp[j][i+1] print(dp[n][m])
Traceback (most recent call last): File "/tmp/tmp04p54ycd/tmpz4k1jfbj.py", line 1, in <module> n = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s187300769
p02235
u253463900
1453285891
Python
Python3
py
Runtime Error
0
0
564
n = int(input()) dataset = [] for i in range(n): tmp = [] tmp.append(input()) tmp.append(input()) dataset.append(tmp) for data in dataset: m = len(data[0]) n = len(data[1]) dp = [] for x in range(n+1): dp.append([0] *(m+1)) for j in range(n): for i in range(m): if data[0][i] == data[1][j]: dp[j+1][i+1] = dp[j][i] + 1 elif dp[j+1][i]>dp[j][i+1]: dp[J+1][i+1] = dp[j+1][i] else: dp[j+1][i+1] = dp[j][i+1] print(dp[n][m])
Traceback (most recent call last): File "/tmp/tmp8o2p1re4/tmp6pddu27z.py", line 1, in <module> n = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s613416658
p02235
u970436839
1453296788
Python
Python
py
Runtime Error
0
0
317
def lcs_size(): X = input() Y = input() a = len(X) b = len(Y) z2 = [0 for i in range(b+1)] for i in range(a): z1 = z2 + [] for j in range(b): if X[i] == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] return z2[-1] q = input() for k in range(q): print lcs_size()
File "/tmp/tmpilqw8dhg/tmpdor4i0tx.py", line 20 print lcs_size() ^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s510584125
p02235
u970436839
1453296876
Python
Python
py
Runtime Error
0
0
330
def lcs_size(): X = input() Y = input() a = len(X) b = len(Y) z2 = [0 for i in range(b+1)] for i in range(a): ch = X[i] z1 = z2 + [] for j in range(b): if Xch == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] return z2[-1] q = input() for k in range(q): print lcs_size()
File "/tmp/tmpgw397qyu/tmp7cxxj0wm.py", line 21 print lcs_size() ^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s971575672
p02235
u970436839
1453296904
Python
Python
py
Runtime Error
0
0
329
def lcs_size(): X = input() Y = input() a = len(X) b = len(Y) z2 = [0 for i in range(b+1)] for i in range(a): ch = X[i] z1 = z2 + [] for j in range(b): if ch == Y[j]: z2[j+1] = z1[j] + 1 else: z2[j+1] = z2[j] return z2[-1] q = input() for k in range(q): print lcs_size()
File "/tmp/tmpf56060c4/tmpakhnrywy.py", line 21 print lcs_size() ^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s932357032
p02235
u069446126
1453308779
Python
Python
py
Runtime Error
0
0
513
q = int(raw_input()) for i in range(q): X = raw_input() Y = raw_input() print LCS(X, Y) def LCS(x, y): dp = {} for i in range(len(x)+1): dp[i] = {0: i} for j in range(len(y)+1): dp[0][j] = j for i in range(1, len(x)+1): for j in range(1, len(y)+1): d = 0 if x[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) longer = max(len(x), len(y)) return (longer - dp[len(x)][len(y)])
File "/tmp/tmps58mfkbw/tmpmbczb9ll.py", line 6 print LCS(X, Y) ^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s911570244
p02235
u069446126
1453308898
Python
Python
py
Runtime Error
0
0
508
def LCS(x, y): dp = {} for i in range(len(x)+1): dp[i] = {0: i} for j in range(len(y)+1): dp[0][j] = j for i in range(1, len(x)+1): for j in range(1, len(y)+1): d = 0 if x[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) longer = max(len(x), len(y)) return (longer - dp[len(x)][len(y)]) q = int(raw_input()) for i in range(q): X = raw_input() Y = raw_input() print LCS(X, Y)
File "/tmp/tmpt3gylrz2/tmpu7e7ze7u.py", line 21 print LCS(X, Y) ^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s693727738
p02235
u069446126
1453308946
Python
Python
py
Runtime Error
0
0
509
def LCS(x, y): dp = {} for i in range(len(x)+1): dp[i] = {0: i} for j in range(len(y)+1): dp[0][j] = j for i in range(1, len(x)+1): for j in range(1, len(y)+1): d = 0 if x[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) longer = max(len(x), len(y)) return (longer - dp[len(x)][len(y)]) q = int(raw_input()) for i in range(q): X = raw_input() Y = raw_input() print(LCS(X, Y))
Traceback (most recent call last): File "/tmp/tmp0curxg5x/tmppnhbml_m.py", line 17, in <module> q = int(raw_input()) ^^^^^^^^^ NameError: name 'raw_input' is not defined
s183121271
p02235
u069446126
1453309177
Python
Python
py
Runtime Error
0
0
509
def LCS(x, y): dp = {} for i in range(len(x)+1): dp[i] = {0: i} for j in range(len(y)+1): dp[0][j] = j for i in range(1, len(x)+1): for j in range(1, len(y)+1): d = 0 if x[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) longer = max(len(x), len(y)) return (longer - dp[len(x)][len(y)]) q = int(raw_input()) for i in range(q): X = raw_input() Y = raw_input() print(LCS(X, Y))
Traceback (most recent call last): File "/tmp/tmphjem787b/tmphfizjvq7.py", line 17, in <module> q = int(raw_input()) ^^^^^^^^^ NameError: name 'raw_input' is not defined
s240466672
p02235
u069446126
1453313747
Python
Python
py
Runtime Error
0
0
489
def LCS(x, y): dp = {} for i in range(len(x)+1): dp[i] = {0: 0} for j in range(len(y)+1): dp[0][j] = 0 for i in range(1, len(x)+1): for j in range(1, len(y)+1): if x[i] == y[j]: dp[i][j] = dp[i-1][j-1] + 1 else: dp[i][j] = max(dp[i][j-1], dp[i-1][j]) return dp[len(x)][len(y)] q = int(raw_input()) for i in range(q): X = raw_input() Y = raw_input() print(LCS(X, Y))
Traceback (most recent call last): File "/tmp/tmpfjzufiow/tmpl5yhsdq5.py", line 18, in <module> q = int(raw_input()) ^^^^^^^^^ NameError: name 'raw_input' is not defined
s596101581
p02235
u047737909
1453343432
Python
Python
py
Runtime Error
0
0
404
def edit_distance(s, t): s=raw_input() t=raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): d = 0 if s[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print solve()
File "/tmp/tmpwxuz622g/tmprfl123uh.py", line 18 print solve() ^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s263841372
p02235
u047737909
1453343506
Python
Python
py
Runtime Error
0
0
416
def edit_distance(s, t): s=raw_input() t=raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): d = 0 if s[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance(s, t)
File "/tmp/tmppbopt417/tmpbg_93733.py", line 18 print edit_distance(s, t) ^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s674274758
p02235
u047737909
1453343811
Python
Python
py
Runtime Error
0
0
416
def edit_distance(s, t): s=raw_input() t=raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): d = 0 if s[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance(s, t)
File "/tmp/tmpoe4pf5m_/tmpwn51srau.py", line 18 print edit_distance(s, t) ^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s635970172
p02235
u047737909
1453343848
Python
Python
py
Runtime Error
0
0
412
def edit_distance(s, t): s=raw_input() t=raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): d = 0 if s[i-1] == t[j-1] else 1 dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance()
File "/tmp/tmpv81ew2ut/tmpxoyfeftd.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s840858095
p02235
u047737909
1453344026
Python
Python
py
Runtime Error
0
0
416
def edit_distance(s, t): s=raw_input() t=raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): if(s[i-1] == t[j-1]): d==0 else: dp[i][j] = min(dp[i-1][j] + 1,dp[i][j-1] + 1,dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance(s, t)
File "/tmp/tmp661buvqb/tmpg3absgkg.py", line 18 print edit_distance(s, t) ^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s311218597
p02235
u047737909
1453344542
Python
Python
py
Runtime Error
0
0
417
def edit_distance(): s = raw_input() t = raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): if (s[i-1] == t[j-1]): d = 0 else: dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance()
File "/tmp/tmp1615n4rx/tmpqj6lbf3y.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s658721522
p02235
u047737909
1453344565
Python
Python
py
Runtime Error
0
0
424
def edit_distance(s, t): s = raw_input() t = raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): if (s[i-1] == t[j-1]): d = 0 else: dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance(s,t)
File "/tmp/tmp326vteea/tmpas4x8yki.py", line 18 print edit_distance(s,t) ^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s090070029
p02235
u047737909
1453344579
Python
Python
py
Runtime Error
0
0
421
def edit_distance(s, t): s = raw_input() t = raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): if (s[i-1] == t[j-1]): d = 0 else: dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance()
File "/tmp/tmpu8y4gd52/tmpgqa01199.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s968580402
p02235
u047737909
1453344769
Python
Python
py
Runtime Error
0
0
424
def edit_distance(s, t): s = raw_input() t = raw_input() dp = {} for i in range(len(s) + 1): dp[i] = {0: i} for j in range(len(t) + 1): dp[0][j] = j for i in range(1, len(s) + 1): for j in range(1, len(t) + 1): if (s[i-1] == t[j-1]): d = 0 else: dp[i][j] = min(dp[i-1][j] + 1, dp[i][j-1] + 1, dp[i-1][j-1] + d) return dp[len(s)][len(t)] n = input() for p in range(n): print edit_distance(s,t)
File "/tmp/tmpvm7pqv1d/tmpg9hig7kt.py", line 18 print edit_distance(s,t) ^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s169148164
p02235
u047737909
1453345719
Python
Python
py
Runtime Error
0
0
339
def edit_distance(): s = raw_input() t = raw_input() a = len(X) b = len(Y) x = [0 for i in range(b+1)] for i in range(a): q = s[i] x2 = x1+[] for j in range(b): if (q ==t[j]): x[j+1] =x2[j]+1 elif (x[j+1]<x2[j]+1): x[j+1] =x2[j] return x1[-1] n = input() for i2 in range(n): print edit_distance()
File "/tmp/tmp49scuc62/tmp0xpnri13.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s567348238
p02235
u047737909
1453345751
Python
Python
py
Runtime Error
0
0
339
def edit_distance(): s = raw_input() t = raw_input() a = len(s) b = len(t) x = [0 for i in range(b+1)] for i in range(a): q = s[i] x2 = x1+[] for j in range(b): if (q ==t[j]): x[j+1] =x2[j]+1 elif (x[j+1]<x2[j]+1): x[j+1] =x2[j] return x1[-1] n = input() for i2 in range(n): print edit_distance()
File "/tmp/tmpossqwjp1/tmp6d49vrsn.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s864007889
p02235
u047737909
1453345911
Python
Python
py
Runtime Error
0
0
328
def edit_distance(): s = raw_input() t = raw_input() a = len(s) b = len(t) x = [0 for i in range(b+1)] for i in range(a): q = s[i] x2 = x1+[] for j in range(b): if (q ==t[j]): x[j+1] =x2[j]+1 elif (x[j+1]<x[j]): x[j+1] =x2[j] return x1[-1] n = input() for i2 in range(n): print edit_distance()
File "/tmp/tmp_myh52ao/tmpzj_euzev.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s562225153
p02235
u047737909
1453345956
Python
Python
py
Runtime Error
0
0
327
def edit_distance(): s = raw_input() t = raw_input() a = len(s) b = len(t) x = [0 for i in range(b+1)] for i in range(a): q = s[i] x2 = x1+[] for j in range(b): if (q ==t[j]): x[j+1] =x2[j]+1 elif (x[j+1]<x[j]): x[j+1] =x2[j] return x[-1] n = input() for i2 in range(n): print edit_distance()
File "/tmp/tmph_aew1ly/tmpa9z4cnay.py", line 18 print edit_distance() ^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s493056117
p02235
u834416077
1453358187
Python
Python
py
Runtime Error
0
0
338
def solve(): X = raw_input() Y = raw_input() a = len(X) b = len(Y) c1 = [0 for i in range(b+1)] for i in range(a): c2 = c1 + [] for j in range(b): if X[i] == Y[j]: c1[j+1] = c2[j] + 1 elif c1[j+1] < c1[j]: c1[j+1] = c1[j] return c1[-1] n = input() for k in range(q): print solve()
File "/tmp/tmpfsfmq730/tmpp2cc_xx1.py", line 20 print solve() ^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s571484453
p02235
u663227983
1453431400
Python
Python
py
Runtime Error
0
0
564
def lcs(x,y): x = " " + x y = " " + y c = [[0]*(len(x)+1)]*(len(y)+1) # for i in xrange (len(x)-1): # c[i][0] = 0 # for j in xrange (len(y)-1): # c[0][j] = 0 for i in xrange (len(x)): for j in xrange (len(y)): if i >= 1 and j >= 1 and x[i] == y[j]: c[i][j] = c[i-1][j-1] + 1 elif i >= 1 and j >= 1 and x[i] != y[j]: c[i][j] = max(c[i][j-1],c[i-1][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmp2ddgebzu/tmpslqykx3v.py", line 24 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s928276322
p02235
u663227983
1453431433
Python
Python
py
Runtime Error
0
0
456
def lcs(x,y): x = " " + x y = " " + y c = [[0]*(len(x)+1)]*(len(y)+1) for i in xrange (len(x)): for j in xrange (len(y)): if i >= 1 and j >= 1 and x[i] == y[j]: c[i][j] = c[i-1][j-1] + 1 elif i >= 1 and j >= 1 and x[i] != y[j]: c[i][j] = max(c[i][j-1],c[i-1][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmplv47wy_t/tmp4fd2im3s.py", line 20 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s797163290
p02235
u663227983
1453431478
Python
Python3
py
Runtime Error
0
0
456
def lcs(x,y): x = " " + x y = " " + y c = [[0]*(len(x)+1)]*(len(y)+1) for i in xrange (len(x)): for j in xrange (len(y)): if i >= 1 and j >= 1 and x[i] == y[j]: c[i][j] = c[i-1][j-1] + 1 elif i >= 1 and j >= 1 and x[i] != y[j]: c[i][j] = max(c[i][j-1],c[i-1][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmpw4k8_2o2/tmpxgqskedl.py", line 20 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s044781711
p02235
u663227983
1453431703
Python
Python
py
Runtime Error
0
0
573
def lcs(x,y): x = " " + x y = " " + y c = [[0]*(len(x)+1)]*(len(y)+1) # for i in xrange (len(x)-1): # c[i][0] = 0 # for j in xrange (len(y)-1): # c[0][j] = 0 for i in xrange (len(x)): for j in xrange (len(y)): if i >= 1 and j >= 1 and x[i] == y[j]: c[i][j] = c[i-1][j-1] + 1 elif i >= 1 and j >= 1 and x[i] != y[j]: c[i][j] = max(c[i][j-1],c[i-1][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmp7usmbgrc/tmp6ykjgf_p.py", line 24 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s068675893
p02235
u663227983
1453432071
Python
Python
py
Runtime Error
0
0
465
def lcs(x,y): x = " " + x y = " " + y c = [[0]*(len(x)+1)]*(len(y)+1) for i in xrange (len(x)): for j in xrange (len(y)): if i >= 1 and j >= 1 and x[i] == y[j]: c[i][j] = c[i-1][j-1] + 1 elif i >= 1 and j >= 1 and x[i] != y[j]: c[i][j] = max(c[i][j-1],c[i-1][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmpvm2dgrs_/tmpkpaplhft.py", line 20 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s387876705
p02235
u663227983
1453443879
Python
Python
py
Runtime Error
0
0
517
def lcs(x,y): xs = len(x) ys = len(y) x = " " + x y = " " + y c = [[0 for i in xrange(len(x))] for j in xrange(len(y))] for i in xrange (1,ys+1): for j in xrange (1,xs+1): if x[j] == y[i]: a = 1 else: a = 0 c[i][j] = max(c[i][j-1],c[i-1][j],c[i-1][j-1] + a) m = max(m,c[i][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmpm8efi0sf/tmpznk0ddhr.py", line 26 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s653333471
p02235
u663227983
1453443900
Python
Python
py
Runtime Error
0
0
512
def lcs(x,y): xs = len(x) ys = len(y) x = " " + x y = " " + y c = [[0 for i in xrange(len(x))] for j in xrange(len(y))] for i in xrange (1,ys+1): for j in xrange (1,xs+1): if x[j] == y[i]: a = 1 else: a = 0 c[i][j] = max(c[i][j-1],c[i-1][j],c[i-1][j-1] + a) m = max(m,c[i][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmp9k_6v712/tmpkgypyfz4.py", line 24 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s019685797
p02235
u663227983
1453443919
Python
Python
py
Runtime Error
0
0
507
def lcs(x,y): xs = len(x) ys = len(y) x = " " + x y = " " + y c = [[0 for i in xrange(len(x))] for j in xrange(len(y))] for i in xrange (1,ys+1): for j in xrange (1,xs+1): if x[j] == y[i]: a = 1 else: a = 0 c[i][j] = max(c[i][j-1],c[i-1][j],c[i-1][j-1] + a) m = max(m,c[i][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmpmubuu6j1/tmp0fezsh2l.py", line 20 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s210628322
p02235
u663227983
1453443928
Python
Python
py
Runtime Error
0
0
502
def lcs(x,y): xs = len(x) ys = len(y) x = " " + x y = " " + y c = [[0 for i in xrange(len(x))] for j in xrange(len(y))] for i in xrange (1,ys+1): for j in xrange (1,xs+1): if x[j] == y[i]: a = 1 else: a = 0 c[i][j] = max(c[i][j-1],c[i-1][j],c[i-1][j-1] + a) m = max(m,c[i][j]) return max(max(c)) n = input() for i in xrange (n): x = raw_input() y = raw_input() print lcs(x,y)
File "/tmp/tmpmmz2vx_4/tmpcr2iai0r.py", line 20 print lcs(x,y) ^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s994896178
p02235
u967035362
1453552892
Python
Python
py
Runtime Error
0
0
575
def main(): num = int(stdin.readline()) for _ in xrange(num): x = stdin.readline().rstrip() y = stdin.readline().rstrip() n = len(y) + 1 cim1 = [0] * n for i, xi in enumerate(x, start=1): ci = [0] * n for j, yj in enumerate(y, start=1): if xi == yj: ci[j] = cim1[j-1] + 1 elif cim1[j] >= ci[j-1]: ci[j] = cim1[j] else: ci[j] = ci[j-1] cim1 = ci print(ci[j]) main()
File "/tmp/tmpg5uo8ood/tmpe2xb6g8f.py", line 22 print(ci[j]) ^ IndentationError: unindent does not match any outer indentation level
s587562278
p02235
u967035362
1453553099
Python
Python
py
Runtime Error
0
0
410
import itertools q = int(input()) for a in range(q): X = input() Y = input() cost = [0] for c in Y: for i in range(len(cost) - 1, -1, -1): index = X.find(c, cost[i]) + 1 if index: if i + 1 < len(cost): cost[i + 1] = min(cost[i + 1], index) else: cost.append(index) print(len(cost) - 1)
Traceback (most recent call last): File "/tmp/tmp6swr7rr6/tmpxex4jcnq.py", line 3, in <module> q = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s269320808
p02235
u967035362
1453553278
Python
Python
py
Runtime Error
0
0
404
import sys q = int(input()) for a in range(q): X = input() Y = input() cost = [0] for c in Y: for i in range(len(cost) - 1, -1, -1): index = X.find(c, cost[i]) + 1 if index: if i + 1 < len(cost): cost[i + 1] = min(cost[i + 1], index) else: cost.append(index) print(len(cost) - 1)
Traceback (most recent call last): File "/tmp/tmp51sxpl8w/tmpc_v3w0in.py", line 3, in <module> q = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s673713584
p02235
u663227983
1453554461
Python
Python
py
Runtime Error
0
0
402
def solve(): x = raw_input() y = raw_input() a, b = len(x), len(y) x1 = [0 for k in range(b+1)] for i in xrange(a): e1 = x[i] x2 = x1+" " for j in xrange(b): if e1 == y[j]: x1[j+1] = x2[j] + 1 elif x1[j+1] < x1[j]: x1[j+1] = x1[j] return x1[-1] n = input() for i2 in range(n): print solve()
File "/tmp/tmptz12lir8/tmp79d8dqaw.py", line 19 print solve() ^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s267546655
p02235
u119456964
1453580133
Python
Python
py
Runtime Error
0
0
467
q = int(raw_input()) for i in range(0, q): X[i] = str(raw_input()) Y[i] = str(raw_input()) def LCS(Max, X, Y): if len(X) == 0 or len(Y) == 0: return Max break else: return Max if X[len(X)] == Y[len(Y)]: Max = LCS(Max, X[:len(X)-1], Y[:len(Y)-1]) + 1 else: Max = max(LCS(Max, X[:len(X)], Y[:len(Y)-1]), LCS(Max, X[:len(X)-1], Y[:len(Y)]) for i in range(0, q): Max = 0 print LCS(Max, X[i], Y[i])
File "/tmp/tmpc07_bvf8/tmp39m0y3a8.py", line 15 Max = max(LCS(Max, X[:len(X)], Y[:len(Y)-1]), LCS(Max, X[:len(X)-1], Y[:len(Y)]) ^ SyntaxError: '(' was never closed
s660724739
p02235
u724923896
1453645966
Python
Python
py
Runtime Error
0
0
447
q = input() X = map(int, raw_input().split)) Y = map(int, raw_input().split)) def edit_distance(s, t) dp = {} for i in range(0. len(s)): dp[i] = {0: i} for j in range(0, len(t)): dp[0][j] = j for i in range(1, len(s)): for j in range(1, len(t)): d = 0 if s[i-1] == j[i-1] else 1 dp[i][j] = min(dp[i-1][j]+1, dp[i][j-1]+1, dp[i-1][j-1]+d) print dp[len(s)][len(t)] edit_distance(X, Y)
File "/tmp/tmpjsvxt535/tmpt98u5ohk.py", line 3 X = map(int, raw_input().split)) ^ SyntaxError: unmatched ')'
s362989327
p02235
u724923896
1453646287
Python
Python
py
Runtime Error
0
0
479
q = input() X = map(int, raw_input().split)) Y = map(int, raw_input().split)) def edit_distance(s, t) dp = {} for i in range(0. len(s)): dp[i] = {0: i} for j in range(0, len(t)): dp[0][j] = j for i in range(1, len(s)): for j in range(1, len(t)): d = 0 if s[i-1] == j[i-1] else 1 dp[i][j] = min(dp[i-1][j]+1, dp[i][j-1]+1, dp[i-1][j-1]+d) print dp[len(s)][len(t)] for k in range(0, q-1): edit_distance(X, Y)
File "/tmp/tmpt2428_lo/tmp2qyla920.py", line 3 X = map(int, raw_input().split)) ^ SyntaxError: unmatched ')'
s823966299
p02235
u253463900
1453646953
Python
Python3
py
Runtime Error
0
0
546
n = int(input()) p = [] a,b = [int(x) for x in input().split()] p.append(a) p.append(b) for i in range(1, n): c,d = [int(x) for x in input().split()] p.append(d) # end input # create dp table dp = [] for x in range(n+1): dp.append([0] * (n+1)) for l in range(2, n+1): for i in range(1, n-l+2): j = i + l -1 dp[i][j] = 9999999999 for k in range(i, j): tmp = dp[i][k] + dp[k+1][j] + (p[i-1] * p[k] * p[j]) if dp[i][j] > tmp: dp[i][j] = tmp #print(dp) print(dp[1][n])
Traceback (most recent call last): File "/tmp/tmptdajseo6/tmpcb6upq7f.py", line 1, in <module> n = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s121163860
p02235
u724923896
1453648252
Python
Python
py
Runtime Error
0
0
387
q = input() def edit_distance() X = raw_input() Y = raw_input() for i in range(0. len(X)): s[i] = i for i in range(1, len(X)): t = s + [] for j in range(1, len(Y)): if s[i-1] == j[i-1]: s[j+1] = t[j] + 1 elif [j+1] < s[j]: s[j+1] = t[j] return s[-1] for k in range(0, q-1): edit_distance()
File "/tmp/tmptqqyofen/tmpeekdtv11.py", line 3 def edit_distance() ^ SyntaxError: expected ':'
s500449742
p02235
u724923896
1453649175
Python
Python
py
Runtime Error
0
0
378
q = input() def common() X = raw_input() Y = raw_input() for i in range(0. len(X)): s[i] = 0 for i in range(1, len(X)): t = s + [] for j in range(1, len(Y)): if s[i-1] == j[i-1]: s[j+1] = t[j] + 1 elif [j+1] < s[j]: s[j+1] = t[j] return s[-1] for k in range(0, q-1): common()
File "/tmp/tmpg85g98nb/tmpdfduw9xr.py", line 3 def common() ^ SyntaxError: expected ':'
s977736950
p02235
u724923896
1453649391
Python
Python
py
Runtime Error
0
0
384
q = input() def common() X = raw_input() Y = raw_input() for i in range(0. len(X)+1): s[i] = 0 for i in range(1, len(X)): t = s + [] for j in range(1, len(Y)): if s[i-1] == j[i-1]: s[j+1] = t[j] + 1 elif s[j+1] < s[j]: s[j+1] = s[j] return s[-1] for k in range(0, q): common()
File "/tmp/tmpuhq8ff51/tmp2kfmsy1g.py", line 3 def common() ^ SyntaxError: expected ':'
s891618332
p02235
u724923896
1453649559
Python
Python
py
Runtime Error
0
0
385
q = input() def common() X = raw_input() Y = raw_input() for i in range(0. len(X)+1): s[i] = 0 for i in range(0, len(X)): t = s + [] for j in range(1, len(Y)): if s[i] == j[i]: s[j+1] = t[j] + 1 elif s[j+1] < s[j]: s[j+1] = s[j] return s[-1] for k in range(0, q): common()
File "/tmp/tmpjwhbtz6u/tmpj44bp2_z.py", line 3 def common() ^ SyntaxError: expected ':'
s154438926
p02235
u724923896
1453649615
Python
Python
py
Runtime Error
0
0
384
def common(): X = raw_input() Y = raw_input() for i in range(0. len(X)+1): s[i] = 0 for i in range(0, len(X)): t = s + [] for j in range(1, len(Y)): if s[i] == j[i]: s[j+1] = t[j] + 1 elif s[j+1] < s[j]: s[j+1] = s[j] return s[-1] q = input() for k in range(0, q): common()
File "/tmp/tmp40dmbxrk/tmptne3fao9.py", line 5 for i in range(0. len(X)+1): ^^^^^^^^^^^ SyntaxError: invalid syntax. Perhaps you forgot a comma?
s475237520
p02235
u724923896
1453649737
Python
Python
py
Runtime Error
0
0
388
def common(): X = raw_input() Y = raw_input() for i in range(0. len(X)+1): s[i] = 0 for i in range(0, len(X)): t = s + [] for j in range(0, len(Y)): if s[i] == j[i]: s[j+1] = t[j] + 1 elif s[j+1] < s[j]: s[j+1] = s[j] return s[-1] q = input() for k in range(0, q): common()
File "/tmp/tmp7vy0t3fx/tmpa2qlnija.py", line 5 for i in range(0. len(X)+1): ^^^^^^^^^^^ SyntaxError: invalid syntax. Perhaps you forgot a comma?
s264145399
p02235
u724923896
1453649842
Python
Python
py
Runtime Error
0
0
392
def common(): X = raw_input() Y = raw_input() for i in range(0. len(X)+1): s[i] = 0 for j in range(0, len(X)): t = s + [] for k in range(0, len(Y)): if s[j] == j[k]: s[k+1] = t[k] + 1 elif s[k+1] < s[k]: s[k+1] = s[k] return s[-1] q = input() for l in range(0, q): common()
File "/tmp/tmp8xj49f58/tmpvm4azrvj.py", line 5 for i in range(0. len(X)+1): ^^^^^^^^^^^ SyntaxError: invalid syntax. Perhaps you forgot a comma?
s036713973
p02235
u724923896
1453650032
Python
Python
py
Runtime Error
0
0
396
def common(): X = raw_input() Y = raw_input() for i in range(0. len(Y)+1): s[i] = 0 for j in range(0, len(X)): t = s + [] for k in range(0, len(Y)): if s[j] == j[k]: s[k+1] = t[k] + 1 elif s[k+1] < s[k]: s[k+1] = s[k] return s[-1] q = input() for l in range(0, q): common()
File "/tmp/tmpiem8k1rh/tmpqf6ealfx.py", line 5 for i in range(0. len(Y)+1): ^^^^^^^^^^^ SyntaxError: invalid syntax. Perhaps you forgot a comma?
s461247401
p02235
u724923896
1453650088
Python
Python
py
Runtime Error
0
0
400
def common(): X = raw_input() Y = raw_input() for i in range(0, len(Y)+1): s[i] = 0 for j in range(0, len(X)): t = s + [] for k in range(0, len(Y)): if s[j] == j[k]: s[k+1] = t[k] + 1 elif s[k+1] < s[k]: s[k+1] = s[k] return s[-1] q = input() for l in range(0, q): common()
Traceback (most recent call last): File "/tmp/tmph0nexasb/tmpsjv7erpy.py", line 18, in <module> q = input() ^^^^^^^ EOFError: EOF when reading a line
s180139066
p02235
u724923896
1453650377
Python
Python
py
Runtime Error
0
0
530
def common(): ??????X = raw_input() ??????Y = raw_input() ???????????????????????????? ??????for i in range(0, len(Y)+1): ????????????s[i] = 0 ???????????????????????????? ??????for j in range(0, len(X)): ????????????t = s + [] ????????????for k in range(0, len(Y)): ??????????????????if X[j] == Y[k]: ????????????????????????s[k+1] = t[k] + 1 ??????????????????elif s[k+1] < s[k]: ????????????????????????s[k+1] = s[k] ?????????????????????? ??????return s[-1] ?????????? q = input()???????? for l in range(0, q): ??????common()
File "/tmp/tmp_1fv2y5v/tmpw1v9y05q.py", line 2 ??????X = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s214796003
p02235
u724923896
1453650549
Python
Python
py
Runtime Error
0
0
374
def common(): X = raw_input() Y = raw_input() for i in range(0, len(Y)+1): s[i] = 0 for j in range(0, len(X)): t = s + [] for k in range(0, len(Y)): if X[j] == Y[k]: s[k+1] = t[k] + 1 elif s[k+1] < s[k]: s[k+1] = s[k] return s[-1] ?????????? q = input()???????? for l in range(0, q): common()
File "/tmp/tmpdjxl_l6l/tmp5y1qqxfc.py", line 17 ?????????? ^ SyntaxError: invalid syntax
s474205052
p02235
u885467869
1453700688
Python
Python
py
Runtime Error
0
0
477
ans = {} roop = input() for k in range(roop): str1 = raw_input() str2 = raw_input() for i in range(len(str1)): ans[i, -1] = 0 for j in range(len(str2)): ans[-1, j] = 0 for i in range (len(str1)): for j in range(len(str2)): if(str1[i] == str2[j]): ans[i, j] = ans[i - 1, j - 1] + 1 else: ans[i, j] = max(ans[i - 1, j], ans[i, j - 1]) print ans[len(str1) - 1, len(str2) - 1]
File "/tmp/tmpm3_o8v99/tmpsv10x6oe.py", line 17 print ans[len(str1) - 1, len(str2) - 1] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s897390295
p02235
u885467869
1453704724
Python
Python
py
Runtime Error
0
0
564
ans = [None] * 1000 for i in xrange(1000): ans[i] = [None] * 1000 for i in range(len1): ans[i][0] = 0 for j in range(len2): ans[0][j] = 0 roop = input() for k in range(roop): str1 = raw_input() str2 = raw_input() len1 = len(str1) + 1 len2 = len(str2) + 1 for i in range (1, len1): for j in range(1, len2): if(str1[i - 1] == str2[j - 1]): ans[i][j] = ans[i -1][j - 1] + 1 else: ans[i][j] = max(ans[i - 1][j], ans[i][j - 1]) print ans[len1 - 1][len2 - 1]
File "/tmp/tmp942hy_q1/tmp0sjco4ty.py", line 6 for j in range(len2): ^ IndentationError: unindent does not match any outer indentation level
s732030696
p02235
u885467869
1453704771
Python
Python
py
Runtime Error
0
0
564
ans = [None] * 1000 for i in xrange(1000): ans[i] = [None] * 1000 for i in range(1000): ans[i][0] = 0 for j in range(1000): ans[0][j] = 0 roop = input() for k in range(roop): str1 = raw_input() str2 = raw_input() len1 = len(str1) + 1 len2 = len(str2) + 1 for i in range (1, len1): for j in range(1, len2): if(str1[i - 1] == str2[j - 1]): ans[i][j] = ans[i -1][j - 1] + 1 else: ans[i][j] = max(ans[i - 1][j], ans[i][j - 1]) print ans[len1 - 1][len2 - 1]
File "/tmp/tmpx1npkbll/tmpn2tjprhg.py", line 6 for j in range(1000): ^ IndentationError: unindent does not match any outer indentation level
s093437327
p02235
u885467869
1453704907
Python
Python
py
Runtime Error
50
14224
557
ans = [None] * 1000 for i in xrange(1000): ans[i] = [None] * 1000 for i in range(1000): ans[i][0] = 0 for j in range(1000): ans[0][j] = 0 roop = input() for k in range(roop): str1 = raw_input() str2 = raw_input() len1 = len(str1) + 1 len2 = len(str2) + 1 for i in range (1, len1): for j in range(1, len2): if(str1[i - 1] == str2[j - 1]): ans[i][j] = ans[i -1][j - 1] + 1 else: ans[i][j] = max(ans[i - 1][j], ans[i][j - 1]) print ans[len1 - 1][len2 - 1]
File "/tmp/tmpxtk6ptp8/tmpgnclwgil.py", line 21 print ans[len1 - 1][len2 - 1] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s437740423
p02235
u885467869
1453705035
Python
Python
py
Runtime Error
40
14280
557
ans = [None] * 1000 for i in xrange(1000): ans[i] = [None] * 1000 for i in range(1000): ans[i][0] = 0 for j in range(1000): ans[0][j] = 0 roop = input() for k in range(roop): str1 = raw_input() str2 = raw_input() len1 = len(str1) + 1 len2 = len(str2) + 1 for i in range (1, len1): for j in range(1, len2): if(str1[i - 1] == str2[j - 1]): ans[i][j] = ans[i -1][j - 1] + 1 else: ans[i][j] = max(ans[i - 1][j], ans[i][j - 1]) print ans[len1 - 1][len2 - 1]
File "/tmp/tmpm8sbj56k/tmppzuqswme.py", line 21 print ans[len1 - 1][len2 - 1] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s837017511
p02235
u824204304
1453710501
Python
Python
py
Runtime Error
0
0
366
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) z = [0 for k in range(b+1)] for i in range(lenx): a = x[i] b = z + [] for j in range(leny): if a == y[i]: z[j+1] = b[j] + 1 elif z[j+1] < z[j]: print max(zz) n = input() for i in xrange(n): solve()
File "/tmp/tmp6cid00tu/tmp4d3barim.py", line 16 print max(zz) IndentationError: expected an indented block after 'elif' statement on line 14
s684989159
p02235
u824204304
1453710561
Python
Python
py
Runtime Error
0
0
365
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) z = [0 for k in range(b+1)] for i in range(lenx): a = x[i] b = z + [] for j in range(leny): if a == y[i]: z[j+1] = b[j] + 1 elif z[j+1] < z[j]: print max(z) n = input() for i in xrange(n): solve()
File "/tmp/tmpddrd2e4n/tmpeztxbmuv.py", line 16 print max(z) IndentationError: expected an indented block after 'elif' statement on line 14
s770669351
p02235
u824204304
1453710763
Python
Python
py
Runtime Error
0
0
395
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) z = [0 for k in range(b+1)] for i in range(lenx): a = x[i] b = z + [] for j in xrange(leny): if a == y[i]: z[j+1] = b[j] + 1 elif z[j+1] < z[j]: z[j+1] = z[j] print max(z) n = input() for i in xrange(n): solve()
File "/tmp/tmprqw6ux2a/tmpe2tg768z.py", line 17 print max(z) ^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s166608139
p02235
u824204304
1453710816
Python
Python
py
Runtime Error
0
0
396
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) z = [0 for k in range(lenx)] for i in range(lenx): a = x[i] b = z + [] for j in xrange(leny): if a == y[i]: z[j+1] = b[j] + 1 elif z[j+1] < z[j]: z[j+1] = z[j] print max(z) n = input() for i in xrange(n): solve()
File "/tmp/tmp1mb3t1yu/tmpxb9ilkg4.py", line 17 print max(z) ^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s733259619
p02235
u824204304
1453710868
Python
Python
py
Runtime Error
0
0
394
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) z = [0 for k in range(lenx)] for i in range(lenx): a = x[i] b = z + [] for j in range(leny): if a == y[i]: z[j+1] = b[j] + 1 elif z[j+1] < z[j]: z[j+1] = z[j] print max(z) n = input() for i in range(n): solve()
File "/tmp/tmphqd1f0jv/tmpfv_01cir.py", line 17 print max(z) ^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s980429637
p02235
u824204304
1453710983
Python
Python
py
Runtime Error
0
0
404
def solve(): x = raw_input() y = raw_input() lenx = len(x) leny = len(y) x1 = [0 for k in range(lenx)] for i in range(lenx): a = x[i] x2 = x1 + [] for j in range(leny): if a == y[i]: x1[j+1] = x2[j] + 1 elif x1[j+1] < x1[j]: x1[j+1] = x1[j] print max(x1) n = input() for i in range(n): solve()
File "/tmp/tmpu15_vvkl/tmpgilqkkwk.py", line 17 print max(x1) ^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
s143640805
p02235
u824204304
1453711695
Python
Python
py
Runtime Error
0
0
353
def solve(): x = raw_input() y = raw_input() a, b = len(x), len(y) dsp1 = [0 for i in xrange(b+1)] for i in xrange(a): dsp2 = dsp1+[] for j in xrange(b): if x[i] == y[j]: dsp1[j+1] = dsp2[j] + 1 elif dsp1[j+1] < dsp1[j]: dsp1[j+1] = dsp1[j] print max(dsp1) n = input() for a in xrange(n): solve()
File "/tmp/tmpn34u73wa/tmpre83vmtd.py", line 11 dsp1[j+1] = dsp2[j] + 1 ^ IndentationError: expected an indented block after 'if' statement on line 10
s546674800
p02235
u920118302
1453716509
Python
Python3
py
Runtime Error
0
0
371
def solveZ(X, Y, Z, x, y): if x < len(X) and y < len(Y): ans = [solveZ(X, Y, Z, x, y+1)] Z.append(Y[y]) for j in range(x, len(X)): if Y[y] == X[j]: ans.append(solveZ(X, Y, Z, j+1, y+1)) return max(ans) else: return len(Z) q = int(input()) for i in range(q): X = input() Y = input() ans[i] = solveZ(X, Y, [], 0, 0) for i in range(q): print(ans[i])
Traceback (most recent call last): File "/tmp/tmpbnn0_dtj/tmp0d9zzf22.py", line 12, in <module> q = int(input()) ^^^^^^^ EOFError: EOF when reading a line
s343484133
p02235
u920118302
1453719225
Python
Python3
py
Runtime Error
0
0
522
def solveZ(X, Y, Z, x, y): if x < len(X) and y < len(Y): ans = [solveZ(X, Y, Z, x, y+1)] for j in range(x, len(X)): if Y[y] == X[j]: Z2 = Z + str(Y[y]) ans.append(solveZ(X, Y, Z2, j+1, y+1)) break return max(ans) else: print(Z) return len(Z) q = int(input()) ans = [[] for i in range(q)] for i in range(q): X = str(input()) Y = str(input()) ans[i] = solveZ(X, Y, "", 0, 0) for i in range(q): print(ans[i])
File "/tmp/tmpa_xhc0y2/tmp8uxi8min.py", line 7 ans.append(solveZ(X, Y, Z2, j+1, y+1)) TabError: inconsistent use of tabs and spaces in indentation
s105812471
p02235
u920118302
1453719316
Python
Python3
py
Runtime Error
0
0
530
def solveZ(X, Y, Z, x, y): if x < len(X) and y < len(Y): ans = [solveZ(X, Y, Z, x, y+1)] for j in range(x, len(X)): if Y[y] == X[j]: Z2 = Z + str(Y[y]) ans.append(solveZ(X, Y, Z2, j+1, y+1)) break return max(ans) else: print(Z) return len(Z) q = int(input()) ans = [[] for i in range(q)] for i in range(q): X = str(raw_input()) Y = str(raw_input()) ans[i] = solveZ(X, Y, "", 0, 0) for i in range(q): print(ans[i])
File "/tmp/tmpmflo838_/tmpt_zogoea.py", line 7 ans.append(solveZ(X, Y, Z2, j+1, y+1)) TabError: inconsistent use of tabs and spaces in indentation
s288658399
p02235
u920118302
1453719362
Python
Python3
py
Runtime Error
0
0
530
def solveZ(X, Y, Z, x, y): if x < len(X) and y < len(Y): ans = [solveZ(X, Y, Z, x, y+1)] for j in range(x, len(X)): if Y[y] == X[j]: Z2 = Z + str(Y[y]) ans.append(solveZ(X, Y, Z2, j+1, y+1)) break return max(ans) else: print(Z) return len(Z) q = int(input()) ans = [[] for i in range(q)] for i in range(q): X = raw_input() Y = raw_input() ans[i] = solveZ(str(X), str(Y), "", 0, 0) for i in range(q): print(ans[i])
File "/tmp/tmp5a7uyhbg/tmp154ti173.py", line 7 ans.append(solveZ(X, Y, Z2, j+1, y+1)) TabError: inconsistent use of tabs and spaces in indentation
s020338029
p02235
u613805578
1453727168
Python
Python
py
Runtime Error
0
0
369
def lcs(): ???x, y = raw_input() ???x_len = len(x) ???y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): ???z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[j+1] = z2[j]:??? ????????? z2[j+1] = z2[j] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmp2c8ra4_9/tmpwsr22jmi.py", line 2 ???x, y = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s864292215
p02235
u613805578
1453727202
Python
Python
py
Runtime Error
0
0
353
def lcs(): ???x, y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[j+1] = z2[j]:??? ????????? z2[j+1] = z2[j] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpwn3zt2bd/tmpcy05mwjd.py", line 2 ???x, y = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s027898147
p02235
u613805578
1453727223
Python
Python
py
Runtime Error
0
0
353
def lcs(): ???x, y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[j+1] < z2[j]:??? ????????? z2[j+1] = z2[j] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpqa0b6_63/tmpqbhvto3i.py", line 2 ???x, y = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s735813229
p02235
u613805578
1453727404
Python
Python
py
Runtime Error
0
0
368
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[j+1] < z2[j]:??? ????????? z2[j+1] = z2[j] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpaudol44z/tmpnrxlxigz.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s636143736
p02235
u613805578
1453727437
Python
Python
py
Runtime Error
0
0
363
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[j+1] < z2[j]:??? ????????? z2[j+1] = z2[j] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpxbsyr96t/tmp7fj3e60p.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s853906731
p02235
u613805578
1453727473
Python
Python
py
Runtime Error
0
0
363
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[k] = y[k]: z2[k+1] = z2[k] + 1 elif z2[k+1] < z2[k]:??? ????????? z2[k+1] = z2[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpn86s0iv_/tmpx7l_bt6z.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s404898208
p02235
u613805578
1453727609
Python
Python
py
Runtime Error
0
0
363
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[i] = y[k]: z2[k+1] = z2[k] + 1 elif z2[k+1] < z2[k]:??? ????????? z2[k+1] = z2[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmp_b2a64pq/tmpms62ii07.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s053468535
p02235
u613805578
1453727635
Python
Python
py
Runtime Error
0
0
364
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[i] == y[k]: z2[k+1] = z2[k] + 1 elif z2[k+1] < z2[k]:??? ????????? z2[k+1] = z2[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpdnrij2rh/tmp85zrvfbg.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s074437144
p02235
u613805578
1453727683
Python
Python
py
Runtime Error
0
0
364
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z1 = z2 + [] for k in range(y_len): if x[i] == y[k]: z1[k+1] = z2[k] + 1 elif z1[k+1] < z1[k]:??? ????????? z1[k+1] = z1[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmp9oot6z2y/tmpa_82yfxg.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s345246555
p02235
u613805578
1453727733
Python
Python
py
Runtime Error
0
0
364
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z2 = z1 + [] for k in range(y_len): if x[i] == y[k]: z1[k+1] = z2[k] + 1 elif z1[k+1] < z1[k]:??? ????????? z1[k+1] = z1[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpnev3ye42/tmpjwfg_zuw.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s598670584
p02235
u613805578
1453727759
Python
Python
py
Runtime Error
0
0
364
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for j in range(x_len): z2 = z1 + [] for k in range(y_len): if x[i] == y[k]: z1[k+1] = z2[k] + 1 elif z1[k+1] < z1[k]:??? ????????? z1[k+1] = z1[k] return z1[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpxixwbng6/tmpdf7qtsh6.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s385418551
p02235
u613805578
1453728157
Python
Python
py
Runtime Error
0
0
378
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for i in range(x_len): z1 = z2 + [] ele = x[i] for k in range(y_len): if x[i] == y[k]: z1[k+1] = z2[k] + 1 elif z1[k+1] < z1[k]:??? ????????? z1[k+1] = z1[k] return z1[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpgpkcc73_/tmps12a9883.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s005612806
p02235
u613805578
1453728584
Python
Python
py
Runtime Error
0
0
377
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] ???for i in range(x_len): z1 = z2 + [] ele = x[i] for k in range(y_len): if ele == y[k]: z2[k+1] = z1[k] + 1 elif z2[k+1] < z2[k]:??? ????????? z2[k+1] = z2[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmppwgciq2q/tmppyrf6we7.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1
s539671265
p02235
u613805578
1453728670
Python
Python
py
Runtime Error
0
0
379
def lcs(): ???x = raw_input() y = raw_input() ???x_len = len(x) y_len = len(y) z2 = [0 for i in range(y_len+1)] for i in range(x_len): z1 = z2 + [] ele = x[i] for k in range(y_len): if ele == y[k]: z2[k+1] = z1[k] + 1 elif z2[k+1] < z2[k]:??? ????????? z2[k+1] = z2[k] return z2[-1] num = input() for l in range(num): print lcs()
File "/tmp/tmpv24q7tng/tmpdw7lw94t.py", line 2 ???x = raw_input() ^ IndentationError: expected an indented block after function definition on line 1