Diferente pentru problema/arbsat intre reviziile #1 si #8

Nu exista diferente intre titluri.

Diferente intre continut:

== include(page="template/taskheader" task_id="arbsat") ==
You are given a natural number, $T$, and $T$ testcases in the following format: a natural number $N$ followed by $N$ points with integer coordinates. For each of the $T$ tests, your program should print $1$ if the given points respect the following condition: any rectangle of positive area (greater than $0$), determined by any two of the $N$ points, contains at least another one of the $N$ points either inside or on the borders. If the condition is not satifsied, your program should print $0$ for that testcase.
Se da un numar natural $T$ si apoi $T$ teste de forma: un numar natural $N$, urmat de $N$ puncte de coordonate intregi. Pentru fiecare dintre cele $T$ teste, trebuie sa se afiseze $1$ daca punctele date respecta urmatoarea conditie: orice dreptunghi de arie mai mare ca $0$ determinat de doua dintre cele $N$ puncte, contine cel putin un alt punct in interior sau pe margini. In caz contrar programul va afisa $0$.
h2. Input
h2. Date de intrare
The input file $arbsat.in$ will contain on the first line $T$, the number of testcases. $T$ tests follow, in the following format: $N$, the number of points, then $N$ lines having the coordinates of the points.
Fişierul de intrare $arbsat.in$ va contine pe prima linie $T$, numarul de teste. Urmeaza $T$ teste de forma: $N$, numarul de puncte, si apoi $N$ linii reprezentand coordonatele in plan ale punctelor date.
h2. Output
h2. Date de ieşire
The output file $arbsat.out$ will contain $T$ values of $0$ or $1$, on separate lines, the $i$-th value representing the answer for the $i$-th testcase in the input file.
În fişierul de ieşire $arbsat.out$ se vor gasi $T$ linii, cu valori $0$ sau $1$, a $i$-a dintre acestea corespunzand raspunsului pentru al $i$-lea test din fisierul de intrare.
h2. Restrictions
h2. Restricţii
* $1 ≤ T ≤ 6$
* $1 ≤ N ≤ 100.000$
* All the coordinates are positive, strictly greater than $0$.
* Coordonatele punctelor sunt pozitive, strict mai mari ca $0$ si mai mici decat $1.000.000.000$.
* **Nu se poate sa existe mai mult de un punct la aceeasi pereche de coordonate**.
h2. Example
h2. Exemplu
table(example). |_. arbsat.in |_. arbsat.out |
| 2

Nu exista diferente intre securitate.

Diferente intre topic forum:

 
7762