Team Ai
Datasetpublic

prithivMLmods/Coder-Stat

Coder-Stat Dataset Overview The Coder-Stat dataset is a collection of programming-related data, including problem IDs, programming languages, original statuses, and source code snippets. This dataset is designed to assist in the analysis of coding patterns, error types, and performance metrics. Dataset Details Modalities Tabular: The dataset is structured in a tabular format. Text: Contains text data, including source code snippets.… See the full description on the dataset page: https://huggingface.co/datasets/prithivMLmods/Coder-Stat.

sourceHugging Faceapache-2.0updated 2y agoView on Hugging Face
3likes139downloads
p00973.html106 linesDownload Raw Back to problem_descriptions
1<h2>Fair Chocolate-Cutting</h2>2 3<p>4  You are given a flat piece of chocolate of convex polygon shape. You are to cut it into two pieces of precisely the same amount with a straight knife.5</p>6 7<p>8  Write a program that computes, for a given convex polygon, the maximum and minimum lengths of the line segments that divide the polygon into two equal areas.9</p>10 11<p>12  The figures below correspond to first two sample inputs. Two dashed lines in each of them correspond to the equal-area cuts of minimum and maximum lengths.13</p>14 15<div style="text-align:center">16  <img src="https://judgeapi.u-aizu.ac.jp/resources/images/ICPCAsia2018_fairChocolateCutting"><br>17  Figure F.1. Sample Chocolate Pieces and Cut Lines18</div>19 20 21<h3>Input</h3>22<p>23  The input consists of a single test case of the following format.24</p>25<pre>26$n$27$x_1$ $y_1$28...29$x_n$ $y_n$30</pre>31 32<p>33  The first line has an integer $n$, which is the number of vertices of the given polygon. Here, $n$ is between 3 and 5000, inclusive. Each of the following $n$ lines has two integers $x_i$ and $y_i$, which give the coordinates ($x_i, y_i$) of the $i$-th vertex of the polygon, in counterclockwise order. Both $x_i$ and $y_i$ are between 0 and 100 000, inclusive.34</p>35 36<p>37  The polygon is guaranteed to be simple and convex. In other words, no two edges of the polygon intersect each other and interior angles at all of its vertices are less than $180^\circ$.38</p>39 40<h3>Output</h3>41<p>42  Two lines should be output. The first line should have the minimum length of a straight line segment that partitions the polygon into two parts of the equal area. The second line should have the maximum length of such a line segment. The answer will be considered as correct if the values output have an absolute or relative error less than $10^{-6}$.43</p>44 45<h3>Sample Input 1</h3>46<pre>474480 04910 05010 10510 1052</pre>53<h3>Sample Output 1</h3>54<pre>55105614.14213562373095048857</pre>58 59<h3>Sample Input 2</h3>60<pre>613620 0636 0643 1065</pre>66 67<h3>Sample Output 2</h3>68<pre>694.24264068711928514647010.071</pre>72 73<h3>Sample Input 3</h3>74<pre>755760 07799999 2000078100000 700007933344 63344801 5000081</pre>82 83<h3>Sample Output 3</h3>84<pre>8554475.58009158002797686120182.5759253986477587</pre>88 89<h3>Sample Input 4</h3>90<pre>91692100 35093101 349946400 3440956400 3441961200 7250971199 724998</pre>99 100<h3>Sample Output 4</h3>101<pre>1024559.20500190279649821036216.7174287968524227104</pre>105 106