code
stringlengths
3
6.57k
split()
np.array(ab)
reshape(n, 2)
np.zeros(10**6 + 2, dtype=np.int64)
np.add.at(res, a, 1)
np.subtract.at(res, b + 1, 1)
np.cumsum(res, out=res)
print(res.max()
d()
int(sys.stdin.readline()
rstrip()
GeometryTopology.Graph(n)
range(n - 1)
map(int, sys.stdin.readline()
split()
g.add_edge(x, y, weight=1)
g.add_edge(y, x, weight=1)
g.bfs(0)
g.find_ancestors()
map(int, sys.stdin.read()
split()
zip(*[iter(ab)
print(g.find_dist(a, b)
a()
sys.stdin.read()
split()
print(a if len(a)
len(b)
b()
map(int, sys.stdin.read()
split()
np.array(a)
np.nonzero(a)
sum()
np.count_nonzero(a)
astype(np.int8)
c()
map(int, sys.stdin.read()
split()
np.array(t)
reshape(n, k)
np.zeros((1, 1)
range(n)
x.reshape(-1, 1)
print("Found" if np.count_nonzero(x == 0)
d()
map(int, sys.stdin.read()
split()
np.zeros((k + 1, w + 1)
zip(*[iter(ab)
np.maximum(dp[1:, a:], dp[:-1, :-a] + b, out=dp[1:, a:])
print(dp[k][w])
a()
map(int, sys.stdin.readline()
split()
print("YES" if m % d == 0 else "NO")
b()
map(int, sys.stdin.readline()
split()
print("?")
print("+")
elif (~f1)
print("-")
print("!")
c()
map(int, sys.stdin.read()
split()
zip(*[iter(ab)
cumor(f[j] for j in range(n)
range(n)
print(*res, sep="\n")
d()
map(int, sys.stdin.readline()
split()
int(sys.stdin.readline()
rstrip()
np.array(sys.stdin.read()
split()
reshape(n, 2)
np.hstack((p1[:, 1:], p1[:, :1])
np.count_nonzero(GeometryTopology.intersect(seg1, seg2)
a()
np.array(sys.stdin.read()
split()
reshape(3, 2)
print((s // 10 * e)
sum()
b()
set("ch, o, k, u".split(", ")
is_choku(s)
len(s)
and (s[-1] in choku_tail)
is_choku(s[:-1])
len(s)
and (s[-2:] in choku_tail)
is_choku(s[:-2])
print("YES" if is_choku(sys.stdin.readline()
rstrip()
c()
map(int, sys.stdin.read()