message
stringlengths
2
44.5k
message_type
stringclasses
2 values
message_id
int64
0
1
conversation_id
int64
276
109k
cluster
float64
23
23
__index_level_0__
int64
552
217k
Provide tags and a correct Python 3 solution for this coding contest problem. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n, 0 ≀ y ≀ m). Your task is to find a maximum s...
instruction
0
101,488
23
202,976
Tags: implementation, math Correct Solution: ``` from fractions import gcd n, m, x, y, a, b = map(int, input().split()) g = gcd(a, b) a, b = a // g, b // g k = min(n // a, m // b) a, b = k * a, k * b x1, x2 = x - (a - a // 2), x + a // 2 y1, y2 = y - (b - b // 2), y + b // 2 d = max(0, 0 - x1) x1, x2 = x1 + d, x2 + d...
output
1
101,488
23
202,977
Provide tags and a correct Python 3 solution for this coding contest problem. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n, 0 ≀ y ≀ m). Your task is to find a maximum s...
instruction
0
101,489
23
202,978
Tags: implementation, math Correct Solution: ``` import sys from fractions import gcd with sys.stdin as fin, sys.stdout as fout: n, m, x, y, a, b = map(int, next(fin).split()) d = gcd(a, b) a //= d b //= d k = min(n // a, m // b) # >_< w = k * a h = k * b best = tuple([float('inf...
output
1
101,489
23
202,979
Provide tags and a correct Python 3 solution for this coding contest problem. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n, 0 ≀ y ≀ m). Your task is to find a maximum s...
instruction
0
101,490
23
202,980
Tags: implementation, math Correct Solution: ``` from fractions import gcd n, m, x, y, a, b = map(int, input().split()) r = gcd(a, b) a, b = a // r, b // r r = min(n // a, m // b) a, b = a * r, b * r cx, cy = (a + 1) // 2, (b + 1) // 2 dx, dy = min(n - a, max(cx, x) - cx), min(m - b, max(cy, y) - cy) print(dx...
output
1
101,490
23
202,981
Provide tags and a correct Python 3 solution for this coding contest problem. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n, 0 ≀ y ≀ m). Your task is to find a maximum s...
instruction
0
101,491
23
202,982
Tags: implementation, math Correct Solution: ``` from fractions import gcd n, m, x, y, a, b = map(int, input().split()) r = gcd(a, b) a, b = a // r, b // r r = min(n // a, m // b) a, b = a * r, b * r cx, cy = (a + 1) // 2, (b + 1) // 2 dx, dy = min(n - a, max(cx, x) - cx), min(m - b, max(cy, y) - cy) print(dx, dy, a + ...
output
1
101,491
23
202,983
Provide tags and a correct Python 3 solution for this coding contest problem. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n, 0 ≀ y ≀ m). Your task is to find a maximum s...
instruction
0
101,492
23
202,984
Tags: implementation, math Correct Solution: ``` from fractions import gcd n, m, x, y, a, b = map(int, input().split()) k = gcd(a, b) a //= k b //= k times = min(n // a, m // b) a *= times b *= times x1 = x - (a + 1) // 2 y1 = y - (b + 1) // 2 if x1 < 0: x1 = 0 if y1 < 0: y1 = 0 if x1 + a > n: x1 -= (x1 + a...
output
1
101,492
23
202,985
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n...
instruction
0
101,493
23
202,986
No
output
1
101,493
23
202,987
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n...
instruction
0
101,494
23
202,988
No
output
1
101,494
23
202,989
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n...
instruction
0
101,495
23
202,990
No
output
1
101,495
23
202,991
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given a rectangle grid. That grid's size is n Γ— m. Let's denote the coordinate system on the grid. So, each point on the grid will have coordinates β€” a pair of integers (x, y) (0 ≀ x ≀ n...
instruction
0
101,496
23
202,992
No
output
1
101,496
23
202,993
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,760
23
203,520
Tags: geometry Correct Solution: ``` from collections import namedtuple from itertools import combinations Point = namedtuple('Point', ['x', 'y']) def read(): x, y = input().split() return Point(int(x), int(y)) def doubled_oriented_area(p1, p2, p3): return (p3.y - p1.y) * (p2.x - p1.x) - (p3.x - p1.x) ...
output
1
101,760
23
203,521
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,761
23
203,522
Tags: geometry Correct Solution: ``` import math import sys from collections import defaultdict def solve(io): N = io.readInt() P = [None] * N for i in range(0, N): X = io.readInt() Y = io.readInt() P[i] = (X, Y) if N <= 4: io.println("YES") return for i in range(0, 3): P[0]...
output
1
101,761
23
203,523
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,762
23
203,524
Tags: geometry Correct Solution: ``` ## necessary imports import sys input = sys.stdin.readline #from math import ceil, floor, factorial; # swap_array function def swaparr(arr, a,b): temp = arr[a]; arr[a] = arr[b]; arr[b] = temp ## gcd function def gcd(a,b): if b == 0: return a return gcd(...
output
1
101,762
23
203,525
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,763
23
203,526
Tags: geometry Correct Solution: ``` import sys input = sys.stdin.readline n = int(input()) if n <= 4: print("YES") exit() A = [None]*n for i in range(n): A[i] = list(map(int,input().split())) def is_colinear(a1,a2,a3): if a1 == a2 or a2 == a3 or a1 == a3: return True x1,y1 = a1 x2,...
output
1
101,763
23
203,527
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,764
23
203,528
Tags: geometry Correct Solution: ``` from decimal import Decimal class Point: def __init__(self,x,y): self.x = x self.y = y def __eq__(self, other): return self.x == other.x and self.y == other.y def __hash__(self): return self.x.__hash__()^self.y.__hash__() class Line: def __init__(self,p1,p2): ...
output
1
101,764
23
203,529
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,765
23
203,530
Tags: geometry Correct Solution: ``` def collinear(a, b, c): return a[0]*(b[1] - c[1]) + b[0]*(c[1] - a[1]) + c[0]*(a[1] - b[1]) def check(a, pt1, pt2): tmp = [] for x in a: if collinear(a[pt1], x, a[pt2]) != 0: tmp.append(x) if len(tmp) < 3: return True x = tmp[0] y...
output
1
101,765
23
203,531
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,766
23
203,532
Tags: geometry Correct Solution: ``` n = int(input()) lst = [] for x in range(n): (a, b) = map(int, input().split()) lst.append((a, b)) def scal(x1, y1, x2, y2, x3, y3): if (x2 - x1) * (y3 - y1) - (x3 - x1) * (y2 - y1) == 0: return True return False def check(): for x in range(n - 2): ...
output
1
101,766
23
203,533
Provide tags and a correct Python 3 solution for this coding contest problem. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessarily distinct). Is it possible to do this in su...
instruction
0
101,767
23
203,534
Tags: geometry Correct Solution: ``` # https://codeforces.com/problemset/problem/961/D def is_linear(A, B, C): return (B[0] - A[0]) * (C[1] - A[1]) == (C[0] - A[0]) * (B[1] - A[1]) def is_line(pos): if len(pos) <= 2: return True A, B = P[pos[0]], P[pos[1]] for p in pos[2:]: ...
output
1
101,767
23
203,535
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,768
23
203,536
Yes
output
1
101,768
23
203,537
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,769
23
203,538
Yes
output
1
101,769
23
203,539
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,770
23
203,540
Yes
output
1
101,770
23
203,541
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,771
23
203,542
Yes
output
1
101,771
23
203,543
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,772
23
203,544
No
output
1
101,772
23
203,545
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,773
23
203,546
No
output
1
101,773
23
203,547
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,774
23
203,548
No
output
1
101,774
23
203,549
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given n points on Cartesian plane. Every point is a lattice point (i. e. both of its coordinates are integers), and all points are distinct. You may draw two straight lines (not necessa...
instruction
0
101,775
23
203,550
No
output
1
101,775
23
203,551
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,951
23
203,902
"Correct Solution: ``` import sys import math n = int(input()) for _ in range(n): xa, ya, ra, xb, yb, rb = map(float, input().split()) distance = math.sqrt((xa-xb)**2 + (ya-yb)**2) if ra + rb >= distance: if (distance + ra < rb): print(-2) elif (distance + rb < ra): ...
output
1
101,951
23
203,903
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,952
23
203,904
"Correct Solution: ``` for _ in range(int(input())): x1, y1, r1, x2, y2, r2 = [float(x) for x in input().split()] distance = ((x1 - x2)**2 + (y1 - y2)**2)**0.5 if distance > r1 + r2: print(0) else: if r1 > r2 and distance + r2 < r1: print(2) elif r1 < r2 and distance ...
output
1
101,952
23
203,905
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,953
23
203,906
"Correct Solution: ``` N=int(input()) for i in range(N): x1,y1,r1,x2,y2,r2=map(float,input().split()) d=((x1-x2)**2+(y1-y2)**2)**0.5 if r1-r2>d: if r1==r2+d: print("1") else: print("2") elif r2-r1>d: if r2==r1+d: print("1") else: ...
output
1
101,953
23
203,907
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,954
23
203,908
"Correct Solution: ``` import math def aux(v): [xa,ya,ra,xb,yb,rb] = v ab = math.sqrt((xb-xa)**2 + (yb-ya)**2) if ab > ra + rb: rst = 0 elif ab + rb < ra: rst = 2 elif ab + ra < rb: rst = -2 else: rst = 1 return(rst) if __name__ == "__main__": ...
output
1
101,954
23
203,909
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,955
23
203,910
"Correct Solution: ``` from math import sqrt n = int(input()) while n: xa, ya, ra, xb, yb, rb = map(float, input().split()) d = sqrt((xb - xa) ** 2 + (yb - ya) ** 2) if ra > d + rb: print(2) elif rb > d + ra: print(-2) elif d > ra + rb: print(0) else: print(1) ...
output
1
101,955
23
203,911
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,956
23
203,912
"Correct Solution: ``` import math num = int(input()) for i in range(num): lst = list(map(float, input().split())) xa, ya, ra = lst[0], lst[1], lst[2] xb, yb, rb = lst[3], lst[4], lst[5] d = math.sqrt((xa - xb)**2 + (ya - yb)**2) if ra + rb < d: print(0) elif d + min(ra, rb) < max(ra,...
output
1
101,956
23
203,913
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,957
23
203,914
"Correct Solution: ``` import math N = int(input()) for i in range(N): x1,y1,r1,x2,y2,r2 = map(float,input().split()) d = math.sqrt(pow(x1 - x2,2.0) + pow(y1 - y2,2.0)) if d < abs(r2 - r1): if r1 > r2: print(2) else: print(-2) elif d <= r1 + r2: print(1) ...
output
1
101,957
23
203,915
Provide a correct Python 3 solution for this coding contest problem. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "2" if $B$ is in $A$, * "-2" if $A$ is in $B$, * "1" if c...
instruction
0
101,958
23
203,916
"Correct Solution: ``` import math N = int(input()) for _ in [0]*N: x1, y1, r1, x2, y2, r2 = map(float, input().split()) dist = math.hypot(x2-x1, y2-y1) if dist+r2 < r1: print(2) elif dist+r1 < r2: print(-2) elif dist <= r1+r2: print(1) else: print(0) ```
output
1
101,958
23
203,917
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,959
23
203,918
Yes
output
1
101,959
23
203,919
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,960
23
203,920
Yes
output
1
101,960
23
203,921
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,961
23
203,922
Yes
output
1
101,961
23
203,923
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,962
23
203,924
Yes
output
1
101,962
23
203,925
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,963
23
203,926
No
output
1
101,963
23
203,927
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,964
23
203,928
No
output
1
101,964
23
203,929
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,965
23
203,930
No
output
1
101,965
23
203,931
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. You are given circle $A$ with radius $r_a$ and with central coordinate $(x_a, y_a)$ and circle $B$ with radius $r_b$ and with central coordinate $(x_b, y_b)$. Write a program which prints: * "...
instruction
0
101,966
23
203,932
No
output
1
101,966
23
203,933
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,277
23
204,554
Yes
output
1
102,277
23
204,555
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,278
23
204,556
Yes
output
1
102,278
23
204,557
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,279
23
204,558
Yes
output
1
102,279
23
204,559
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,280
23
204,560
Yes
output
1
102,280
23
204,561
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,281
23
204,562
No
output
1
102,281
23
204,563
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,282
23
204,564
No
output
1
102,282
23
204,565
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,283
23
204,566
No
output
1
102,283
23
204,567
Evaluate the correctness of the submitted Python 3 solution to the coding contest problem. Provide a "Yes" or "No" response. A Pythagorean triple is a triple of integer numbers (a, b, c) such that it is possible to form a right triangle with the lengths of the first cathetus, the second cathetus and the hypotenuse equ...
instruction
0
102,284
23
204,568
No
output
1
102,284
23
204,569
Provide tags and a correct Python 3 solution for this coding contest problem. One day Vasya painted a Cartesian coordinate system on a piece of paper and marked some set of points (x1, y1), (x2, y2), ..., (xn, yn). Let's define neighbors for some fixed point from the given set (x, y): * point (x', y') is (x, y)'s ...
instruction
0
102,317
23
204,634
Tags: implementation Correct Solution: ``` def isLeft(pt,pt_l): return (pt[1] == pt_l[1] and pt_l[0]<pt[0]) def isRight(pt,pt_r): return (pt[1] == pt_r[1] and pt_r[0]>pt[0]) def isUpper(pt,pt_u): return (pt[1]< pt_u[1] and pt_u[0]==pt[0]) def isLower(pt,pt_lo): return (pt[1] > pt_lo[1] and pt_lo[...
output
1
102,317
23
204,635