Problems
Pick a problem and write your solution in the built-in editor. The judge runs it against real test cases while you watch, and the wider archive is open to read whenever you like.
Total results1,917 problems
| Title | Level | Topics | Solved | Time limit | Memory limit | Judge |
|---|---|---|---|---|---|---|
| Celestial MapCount stars that, d years ago, lay in a plane through the origin and were exactly d from the origin. | Medium4 | GeometryMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Justice Rains from Above!Given each robot's coordinates and missile speed, output the robot indices sorted by hit time (distance divided by speed), breaking ties by smaller index. | Medium4 | SortingMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Galactic ConfederationGiven M planes and N planet positions, count how many planets fall in the most populated region formed by the planes. | Medium4 | GeometryHash map+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Coast GuardDecide whether a coast guard boat can intercept a thief heading straight out to sea 12 miles away, given their speeds and starting distance apart. | Medium4 | GeometryMath+2 | No attempts yet | 2s | 512 MB | Judgeable |
| ElevatorGiven a rectangle and two circles, decide whether both circles fit inside the rectangle without overlapping. | Medium4 | GeometryMath | No attempts yet | 2s | 512 MB | Judgeable |
| Minimum Queen MovesGiven a queen's start and target square on an 8x8 board, print the minimum number of queen moves needed. | Medium4 | MathImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Colored CubesCount how many distinct cube colorings appear in each test case, where two cubes match if some rotation makes all six face colors agree. | Medium4 | ImplementationHash map+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Square DealGiven three rectangles, decide whether they can be glued edge to edge into a square, with rotations allowed. | Medium4 | GeometryImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| RasterizationCount the pixel centers inside or on a triangle with integer-coordinate corners, handling the collinear case as a segment. | Medium4 | GeometryImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Careful AscentGiven a target point and vertical strips that scale horizontal speed, find the launch horizontal velocity so the craft reaches the target at vertical speed 1. | Medium4 | MathImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Balls and NeedlesGiven K segments in 3D defined by endpoint triples, decide whether they form a closed cycle in space and whether their projections onto the xy-plane form a closed cycle. | Medium4 | GraphUnion-find+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Amusement Park QueueTwo people walk a fixed grid path one step per minute, offset by K minutes; count the minutes their cells touch in any of eight directions. | Medium4 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| MoocastEach cow has a point and a broadcast radius; find the starting cow whose one-way reachable set is largest. | Medium4 | GraphDFS+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Rebel Against The Empire (Small)Given stationary points in 3D, find the smallest jump radius that lets you reach asteroid 1 from asteroid 0, ignoring the time limit. | Medium4 | GraphUnion-find+2 | No attempts yet | 5s | 512 MB | Judgeable |
| BeachCount the hexagon edges that separate land from water, ignoring any edge on the outer border of the map. | Medium4 | ImplementationMatrix+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Three SquareGiven three rectangles, decide whether they can be rotated and placed without overlap to exactly fill a square. | Medium4 | GeometryImplementation+1 | No attempts yet | 1s | 512 MB | Judgeable |
| Hunter's ApprenticeGiven the vertices of a simple polygon in the order placed, decide whether they run counter-clockwise (print fight) or clockwise (print run). | Medium4 | GeometryMath | No attempts yet | 2s | 512 MB | Judgeable |
| IeumjulGiven a rectangle's width and height, compute the dimensions of the poster after the folded shape is determined geometrically. | Medium4 | GeometryMath+1 | No attempts yet | 1s | 64 MB | Judgeable |
| Venue Rental (Small)Given up to 100 axis-aligned rectangles, find the area of the union of all rectangles. | Medium4 | ArrayImplementation+2 | No attempts yet | 2s | 256 MB | Judgeable |
| Ample Syrup (Small)Choose K pancakes from at most 10 to stack largest radius on the bottom, maximizing the exposed surface area divided by pi. | Medium4 | Brute forceSorting+2 | No attempts yet | 5s | 512 MB | Judgeable |
| Jaehong's LadderGiven a rectangle's width, height, and a number of vertical strips, sum the lengths of the N-1 rungs where the strips cross the rectangle's diagonals. | Medium4 | MathGeometry+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Forest PictureDraw an ASCII forest on an M by M canvas from tree or stump coordinates, clipping shapes that fall outside and framing the result with asterisks. | Medium4 | ImplementationSimulation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Anti-missile interceptGiven the missile parabola and the anti-missile launch point and speed, decide the firing time and angle that intercepts at time tK, or report failure. | Medium4 | GeometryMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Hook or Be HookedEach polygon has a squared radius equal to its farthest vertex from the origin; find the K-th smallest such value and print it with two decimals. | Medium4 | GeometrySorting+2 | No attempts yet | 1s | 512 MB | Judgeable |
| Two BoxesGiven two axis-aligned rectangles, classify how they intersect: overlapping interiors (FACE), sharing a segment (LINE), touching at one point (POINT), or disjoint (NULL). | Medium4 | GeometryImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Voronoi VillagesGiven N village positions on a line, find the smallest finite Voronoi neighbourhood size and print it with one decimal digit. | Medium4 | SortingGeometry+2 | No attempts yet | 2s | 512 MB | Judgeable |
| OBB (Oriented Bounding Box)Given two rotated 2D rectangles as vertex lists, test whether their areas overlap using the separating axis theorem on four edge normals. | Medium4 | GeometryMath+1 | No attempts yet | 0.3s | 32 MB | Judgeable |
| Uphill and GahuiGiven a polyline of checkpoints and two query positions, output the absolute average slope between them as a reduced fraction. | Medium4 | GeometryMath+1 | No attempts yet | 1s | 256 MB | Judgeable |
| Janitor TroublesGiven four side lengths that can form a quadrilateral, output its maximum possible area, given by Brahmagupta's formula with the semiperimeter. | Medium4 | MathGeometry+1 | No attempts yet | 1s | 512 MB | Judgeable |
| Goat RopeGiven a point outside an axis-aligned rectangle, print the minimum distance from the point to the rectangle's boundary. | Medium4 | GeometryMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Partition of a CircleA circle is cut by two straight lines, giving four regions with three known boundary lengths; find the fourth length opposite the third. | Medium4 | GeometryMath+1 | No attempts yet | 1s | 512 MB | Judgeable |
| Circle Expert JinwooGiven the radii of the three excircles of a triangle, compute the incircle radius without constructing any triangle explicitly. | Medium4 | MathGeometry+1 | No attempts yet | 1s | 512 MB | Judgeable |
| Are You Listening?Given your point and n listening circles, find the largest radius centered there overlapping at most two of them; output the floor of it, or 0 if three already cover you. | Medium4 | GeometryMath+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Good Pizza, Great PizzaGiven N points, find the area of the smallest 45-degree tilted square (rhombus) that contains all of them. | Medium4 | GeometryMath+2 | No attempts yet | 1s | 256 MB | Judgeable |
| Dome ConstructionGiven n points in 3D with non-negative y, find the minimum radius of a dome (hemisphere on the xz-plane) that contains at least k of them. | Medium4 | Binary searchGeometry+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Chopping on LineA triangle is traced on a rectangular sheet; find the order of the three edge-line cuts that minimizes total cut length, with a fixed tie-break order. | Medium4 | GeometryBrute force+2 | No attempts yet | 1s | 512 MB | Judgeable |
| Professor, I Want a JobGiven an N x N grid of desks, decide whether Seonggyu can escape the professor: distance at least 5 and at least three other students inside the rectangle or segment between them. | Medium4 | ImplementationBrute force+1 | No attempts yet | 1s | 256 MB | Judgeable |
| Hiding NutsGiven N grid points, pick the one minimizing the sum of Manhattan distances to all other points, breaking ties by smallest X then smallest Y. | Medium4 | MathBrute force+2 | No attempts yet | 1s | 512 MB | Judgeable |
| TATCKFor each test case, find the area of the smallest axis-aligned square that contains all given points. | Medium4 | GeometryMath+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Isosceles trianglesCount the isosceles triangles whose three vertices are vertices of a regular n-gon, for n up to 1e9. | Medium4 | CombinatoricsMath+2 | No attempts yet | 1s | 512 MB | Judgeable |
| High-Rise BuildingsGiven the heights of N buildings in a row, find the maximum number of other buildings visible in a straight line of sight from any single building. | Medium5 | GeometryBrute force+2 | No attempts yet | 2s | 128 MB | Judgeable |
| Expandable Beautiful TrianglesCount the RGB-colored triangles on an N by M grid that share two vertices with another RGB triangle of strictly larger area. | Medium5 | Brute forceGeometry+2 | No attempts yet | 2s | 128 MB | Judgeable |
| Going HomeCompute the minimum time to reach the origin from (X,Y) by combining unit-speed walking with fixed-length D jumps costing T seconds each. | Medium5 | MathGeometry+1 | No attempts yet | 2s | 128 MB | Judgeable |
| Cutting to a TriangleGiven a convex polygon reduced to a triangle by repeatedly cutting ears, find the maximum possible area of the final triangle among its vertices. | Medium5 | GeometryBrute force+1 | No attempts yet | 2s | 128 MB | Judgeable |
| Protecting Three PeopleGiven a simple polygon with up to 10,000 vertices, determine for three query points whether each lies inside or on the polygon's boundary. | Medium5 | GeometryMath+1 | No attempts yet | 2s | 128 MB | Judgeable |
| Convex HullCompute the convex hull of up to 100,000 points and count only the hull's true vertices, excluding collinear boundary points. | Medium5 | GeometrySorting+1 | No attempts yet | 2s | 128 MB | Judgeable |
| LaserGroup buildings by the ray from the origin, sort each group by distance, and find buildings whose laser is blocked by a closer, equally tall or taller building. | Medium5 | GeometrySorting+2 | No attempts yet | 2s | 128 MB | Judgeable |
| Communicating with the Space GodsGiven points with some already connected, find the minimum total length of new passages needed to connect all points into one network. | Medium5 | Minimum spanning treeUnion-find+2 | No attempts yet | 2s | 128 MB | Judgeable |
| Field Mouse EscapeGiven mouse and tunnel coordinates plus a max travel distance, compute the minimum number of mice that cannot be matched to a distinct tunnel using bipartite matching. | Medium5 | GraphGreedy+1 | No attempts yet | 2s | 128 MB | Judgeable |
| Vegetarian Pool DividerGiven one endpoint on the boundary of a fixed right isosceles triangle, compute the other endpoint of a segment that splits the triangle into two equal-area regions. | Medium5 | GeometryMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| TripletsGiven a grid with letters placed on some cells, count how many triples of letters are collinear. | Medium5 | GeometryCombinatorics+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Crane DeliveryGiven cranes with fixed positions and reach radii starting from a fixed entrance point, decide for each of K target points whether it lies in the union-reachability graph of overlapping crane discs starting from the entrance. | Medium5 | GraphUnion-find+1 | No attempts yet | 1s | 128 MB | Judgeable |
| ASCII FigureGiven a grid picture drawn with '.', '/', and '\' forming one closed polygon from diagonal cell segments, compute the polygon's area. | Medium5 | GeometryMatrix+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Circles on a ScreenGiven up to 100 circles drawn on a w×h grid, count how many pixels remain black after the union of circles is painted white. | Medium5 | GeometrySimulation+1 | No attempts yet | 3s | 256 MB | Judgeable |
| Simple PolygonOrder given points into a specific simple polygon by picking a bottom-most anchor and sorting the rest by polar angle with a special tie-break for collinear groups. | Medium5 | GeometrySorting+1 | No attempts yet | 1s | 128 MB | Judgeable |
| HighwayGiven villages near a segment highway, find the minimum number of points on the segment so every village lies within distance D of some chosen point. | Medium5 | GreedyGeometry+1 | No attempts yet | 1s | 128 MB | Judgeable |
| 3-Sided DiceDetermine whether a target 3-outcome probability vector lies in the convex hull (with strictly positive weights) of three given dice's probability vectors. | Medium5 | GeometryMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Area of PolygonsGiven a simple integer-coordinate polygon, count how many unit grid squares have nonzero area of intersection with it. | Medium5 | GeometrySimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Windmill AnimationSimulate a line rotating counter-clockwise about a pivot point, switching pivot whenever the line hits another of the given points, and report the first S pivots. Repeat for each dataset. | Medium5 | GeometrySimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Folding GameFor each fold sequence on a rectangle, count how many paper layers sit under a given point. | Medium5 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Underground CablesGiven up to 1000 points in the plane, find the minimum total length of non-crossing straight cables that connect all points. | Medium5 | Minimum spanning treeGraph+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Logo 2One numeric argument in a turtle graphics program is missing; find the value that makes the turtle return to its starting point. | Medium5 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Hermes' ColonyFor each province of 3 or 4 planar points, compute the length of the minimum Steiner tree connecting the cities, allowing extra junction points. | Medium5 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| War on WeatherCount how many surface targets have at least one satellite with a clear line of sight that does not pass through the Earth. | Medium5 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Treasure MapGiven a step list and a magnetic declination, rotate every heading and find the minimum distance between the two resulting polylines. | Medium5 | GeometryImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Building the ConstellationGiven n points in the plane, connect all of them with straight segments of Euclidean length so the total cost is minimized. | Medium5 | Minimum spanning treeGraph+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Chocolate Chip CookiesGiven up to 200 points, find the maximum number that fit inside any circle of radius 2.5 cm, allowing the circle to extend past the dough edge. | Medium5 | GeometryBrute force+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Thinking Inside the BoxFor each test case, report every stored Data Box that intersects, touches, or overlaps at least one Query Box, accounting for longitude wraparound. | Medium5 | GeometryIntervals+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Crash and Go(relians)After each Gorelian lands in order, groups merge when one radio reaches another, meeting at the unweighted average of group positions and combining ranges by root sum of squares; report the final group count. | Medium5 | SimulationUnion-find+2 | No attempts yet | 1s | 128 MB | Judgeable |
| SquaresCount the number of squares whose four corners all come from a given set of integer-coordinate points, allowing tilted squares. | Medium5 | GeometryHash map+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Dividing the LandFor each test case, split N cities with K-1 evenly spaced vertical or horizontal cuts, avoid cuts through cities, and print the minimum average |count - N/K| as a reduced fraction. | Medium5 | SortingMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Cut the CakeSimulate n vertical cuts on a rectangular cake, tracking each rectangular piece and reassigning ids by area, then print all final piece areas sorted. | Medium5 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Polygonal Line Shape SearchGiven a template orthogonal polygonal line, report which of up to 50 other lines match its shape under rotation and translation. | Medium5 | GeometryImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| ConstellationsGiven up to 500 star coordinates, connect each star to its nearest neighbor(s) and count the connected components of the resulting graph. | Medium5 | GraphUnion-find+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Bat PositioningFind the point that equals the centroid of exactly the pointers lying at least 100 units away from it, rounding coordinates to the nearest integer. | Medium5 | GeometryImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Foreclosure BoroughFor each polygon borough, compute the percentage of houses inside it that are in foreclosure, sort boroughs by rate, and print two-decimal rates with tie-breaking by borough number. | Medium5 | GeometrySorting+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Electrical EngineeringFor each query point, find the strongest signal among routers whose segment to the point crosses no polygon wall, using 1/d^2 falloff. | Medium5 | GeometryBrute force+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Time Is MoneyWe choose N-1 links forming a spanning tree minimizing SumTime*SumMoney, where each edge has a time and a money cost. | Medium5 | Minimum spanning treeGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Bovine Bridge BattleCount sets of four points that are symmetric about some center, where each point pairs with its 180-degree rotation partner. | Medium5 | Hash mapGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Radar InstallationEach island on the sea side of a line must be covered by radars of reach d placed on the line, so find the minimum number of placements or report -1 if some island is unreachable. | Medium5 | GreedyIntervals+2 | No attempts yet | 1s | 128 MB | Judgeable |
| The Loathesome Hay BalerRollers touch when center distance equals the sum of radii; find the path from the drive roller to the take-off roller and sum the absolute speeds, truncated. | Medium5 | GraphDFS+2 | No attempts yet | 1s | 128 MB | Judgeable |
| AreaGiven the move vectors of a robot tracing a grid polygon, compute the number of interior grid points, boundary grid points, and the area using Pick's theorem. | Medium5 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| GridlandFor a rectangular grid of towns with eight-direction roads, compute the length of the shortest tour that visits every town once and returns to the start. | Medium5 | MathGreedy+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Horseshoe ScoringScore each four-toss turn by deciding ringer, toucher, swinger, or zero for each horseshoe and summing the points. | Medium5 | GeometryImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| EquidistanceGiven coordinates of locations on a sphere, for each query find the surface distance from a third point to the great circle equidistant from two given points. | Medium5 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Bee MajaConvert a spiral hex-grid cell number into hexagonal axial coordinates using the orientation shown in the sample. | Medium5 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Building a New DepotGiven the corner posts of an axis-aligned rectilinear polygon (listed in no particular order), reconstruct the polygon and compute its total perimeter. | Medium5 | GeometrySorting+2 | No attempts yet | 1s | 128 MB | Judgeable |
| The Perfect SymmetryGiven a set of distinct integer points, decide whether it has a center of symmetry and, if so, print that center to one decimal place. | Medium5 | Hash mapGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| CookiesGiven up to 10 points, find the diameter of the smallest enclosing circle. | Medium5 | GeometryBrute force+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Polygon AreaGiven a grid-aligned orthogonally convex polygon as a string of unit moves, compute its area. | Medium5 | GeometryImplementation+1 | No attempts yet | 1s | 1024 MB | Judgeable |
| Space AntGiven N points with distinct x and y coordinates, output the order produced by repeatedly picking the most clockwise remaining point from the current one. | Medium5 | GeometrySorting+2 | No attempts yet | 1s | 128 MB | Judgeable |
| GunmanEach window is a rectangle at a distinct depth; decide whether one straight ray fired from the X axis can pass through all of them. | Medium5 | GeometryBinary search+2 | No attempts yet | 2s | 128 MB | Judgeable |
| DancersRepeatedly pair the two closest unpaired dancers, breaking ties by smaller indices, and output all pairs sorted. | Medium5 | SortingGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Deepest StationGiven a surface point (x, y) and depth d, decide whether a single 45-degree staircase reaches (0,0,d), it is impossible, or print the shallowest intermediate lobby. | Medium5 | GeometryMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Tiling VerificationGiven a floor and up to 100 rectangles, decide whether they overlap, stick out of the floor, or fail to cover it, printing which condition fails first. | Medium5 | GeometryImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Yum YumFind the minimum number of straight lines needed to cover every integer-coordinate point in an (n+1) by (m+1) grid, excluding the frog's one starting point. | Medium5 | MathNumber theory+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Telephone ExchangePick an integer tower height so the fees from houses fully covered by the circle exceed the height-dependent maintenance cost by as much as possible. | Medium5 | GeometrySorting+2 | No attempts yet | 1s | 512 MB | Judgeable |
| Phone PlotClassify each phone number as EXCELLENT, GOOD, or BAD by counting the fewest straight segments that cover its keypad trace. | Medium5 | GeometrySimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| SymmetryDecide whether the given dots mirror exactly across some vertical line, printing YES or NO for each test case. | Medium5 | Hash mapGeometry+1 | No attempts yet | 1s | 128 MB | Judgeable |
| BridgeConnect all axis-parallel rectangular islands with bridges of minimum total squared shortest gap distance. | Medium5 | Minimum spanning treeGeometry | No attempts yet | 1s | 128 MB | Judgeable |