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 results6,398 problems
| Title | Level | Topics | Solved | Time limit | Memory limit | Judge |
|---|---|---|---|---|---|---|
| Read Phone Number (Small)Split each digit string into the given group lengths and read each run of equal digits with count words such as double and triple. | Easy2 | SimulationString+1 | No attempts yet | 5s | 512 MB | Judgeable |
| Tic-Tac-Toe-Tomek (Small)Given a 4 by 4 tic-tac-toe board with a wildcard T, report whether X won, O won, the game is a draw, or play continues. | Easy2 | ImplementationMatrix | No attempts yet | 5s | 512 MB | Judgeable |
| Tic-Tac-Toe-Tomek (Large)Given a 4x4 tic-tac-toe board with a wildcard T, report whether X won, O won, the game is a draw, or play continues. | Easy2 | ImplementationBrute force+1 | No attempts yet | 5s | 512 MB | Judgeable |
| Proprietary ProblemA product key entry field is shown; the task appears to require validating or generating a key in the format XXXXX-XXXXX-XXXXX-XXXXX-XXXXX. | Easy2 | StringImplementation | No attempts yet | 1s | 1024 MB | Judgeable |
| Dr. Spaceman's height algorithmCompute a child height range from both parents' heights and the child sex, then round both ends inward to whole inches. | Easy2 | ImplementationMath | No attempts yet | 5s | 512 MB | Judgeable |
| Program within a Program (Small)Given N, output the fixed 27-line robot program with nine lines filled in from the binary digits of N. | Easy2 | Implementation | No attempts yet | 5s | 512 MB | Judgeable |
| Reverse Word OrderGiven N lines of space-separated words, print each line's words in reverse order prefixed with the case number. | Easy2 | StringImplementation | No attempts yet | 5s | 512 MB | Judgeable |
| Reverse Words (Large)Read each line of words and print the words in reverse order, prefixed by the case number. | Easy2 | StringImplementation | No attempts yet | 5s | 512 MB | Judgeable |
| T9 Spelling (Small)Map each letter of a short message to its keypad digit and repeat count, inserting a space between consecutive letters that share the same key. | Easy2 | StringImplementation+2 | No attempts yet | 5s | 512 MB | Judgeable |
| Immigrate to the CTP principalityConvert each item between uppercase letters and their alphabet positions (A=1 to Z=26), in the direction given by the mode character. | Easy2 | ImplementationString+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Mini Fantasy WarFor each character, add gear changes to the four base stats, clamp HP and MP to at least 1 and attack to at least 0, then print the weighted combat power. | Easy2 | ImplementationMath | No attempts yet | 1s | 128 MB | Judgeable |
| StarmanGiven up to 100 year ranges, print the Bowie albums released within each range, in release order, with a count first. | Easy2 | ArrayImplementation | No attempts yet | 1s | 128 MB | Judgeable |
| Bitwise Operations on Binary NumbersGiven two equal-length binary strings, output their bitwise AND, OR, XOR, and the complemented forms of each, keeping length and leading zeros. | Easy2 | StringBit manipulation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Changyong's ClockTrack a clock's time on a 24-hour dial, turning it forward or backward by c seconds and answering queries for the current time. | Easy2 | SimulationMath+1 | No attempts yet | 1s | 512 MB | Judgeable |
| LobbyGiven the seat counts of two parties, find how many independents must vote yes for a strict majority. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| CamerasRead n eight-character plates and print each one that matches a fixed pattern of digits and a capital letter, in input order. | Easy2 | StringImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Three SumsFor each N, print the sum of the first N positive integers, the first N odd numbers, and the first N even numbers. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| FormulaGiven triangle vertex coordinates and a measured incircle radius, compute the radius from the formula and print the percentage difference. | Easy2 | GeometryMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Adding god to nicknamesGiven N nicknames split into syllables by spaces, replace the first syllable with god and print the result. | Easy2 | StringImplementation | No attempts yet | 1s | 512 MB | Judgeable |
| Router 4Print the fixed two-layer router built from N inputs, r merge nodes, r split nodes, and N outputs, with M = 2N + r^2 connections. | Easy2 | ImplementationSimulation | No attempts yet | 2s | 512 MB | Judgeable |
| Manhattan TaxiGiven your waiting intersection and up to 100 taxi positions on a 100x100 grid, print the coordinates of the taxi with the smallest Manhattan distance. | Easy2 | ImplementationBrute force+2 | No attempts yet | 2s | 512 MB | Judgeable |
| MatchesFor each match length, decide whether it fits in a W by H box, meaning its length is at most the diagonal sqrt(W^2+H^2). | Easy2 | GeometryMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Chop CupTrack which of three cups hides the ball after a sequence of swaps given as letters A, B, and C. | Easy2 | SimulationImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Tic Tac ToeRead a 3x3 board of X, O, and dots and print YES if some row, column, or diagonal has three equal non-dot symbols. | Easy2 | ImplementationMatrix+1 | No attempts yet | 2s | 512 MB | Judgeable |
| The real Manhattan distanceGiven two points (x, y, floor), compute the walking distance: down from each floor, plus Manhattan street distance. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| PalindromeGiven a lowercase word of at most 20 characters, decide whether it reads the same forwards and backwards. | Easy2 | StringTwo pointers+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Collatz SequenceStarting from n, repeatedly apply the Collatz rule (halve evens, 3n+1 for odds) and print every value from n down to 1 on one line. | Easy2 | SimulationImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| ChessboardPrint an N by M grid of asterisks and dots where the top left cell is an asterisk and adjacent cells always differ. | Easy2 | ArrayImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Least Common MultipleGiven two integers below 100,000,000, print their least common multiple, which can exceed the 32-bit range. | Easy2 | MathNumber theory+1 | No attempts yet | 2s | 512 MB | Judgeable |
| A New AlphabetReplace each English letter with its fixed symbol string from a 26-entry table, leaving all other characters unchanged. | Easy2 | StringHash map+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Quick EstimatesRead N integers up to 10^100 and print the number of digits in each, counting 0 as one digit. | Easy2 | StringMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Room AssignmentCount boys and girls per grade and sum the ceiling of each count divided by the room capacity K. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Jumbled CompassGiven two compass directions from 0 to 359, print the signed rotation with the smallest magnitude that moves the needle from the first direction to the second, breaking ties toward clockwise. | Easy2 | MathImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Four Arithmetic OperationsEach line gives an expression a op b = c with single-digit spacing, and you print correct or wrong answer depending on whether the arithmetic matches the claimed result. | Easy2 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| László BabaiFor each of up to 100 test cases, decide whether two simple graphs on 3 vertices given by their edge lists are isomorphic. | Easy2 | GraphBrute force+1 | No attempts yet | 1s | 256 MB | Judgeable |
| Anniversary CakeGiven a rectangle and two interior candles, output the specific cut described by a fixed rule that separates the candles. | Easy2 | GeometryImplementation+1 | No attempts yet | 2s | 256 MB | Judgeable |
| Boys and GirlsArrange n children in a circle with B/G so that exactly x stand next to a boy and exactly y next to a girl, output the lexicographically smallest. | Easy2 | ImplementationBrute force+1 | No attempts yet | 2s | 256 MB | Judgeable |
| Data PlanTrack monthly data allowance that rolls over, subtract each month's usage, and report the megabytes available in month N+1. | Easy2 | ImplementationMath | No attempts yet | 1s | 64 MB | Judgeable |
| Cleaning StationsGiven weights and a feature matrix, print the indices of the rows whose weighted sum is largest, in ascending order, for each of K data sets. | Easy2 | ImplementationArray+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Walking in timeGiven three credit values, decide whether choosing some of them with signs (+ or -) sums to zero using at least one credit. | Easy2 | Brute forceMath+1 | No attempts yet | 1s | 512 MB | Judgeable |
| Lost BootsCount how many left-right pairs of boots share the same size, reading several test cases until EOF. | Easy2 | Hash mapImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Optical mark readingFor each question, read five grey levels; print the single alternative whose value is at most 127, or * if zero or more than one qualify. | Easy2 | ImplementationBrute force | No attempts yet | 2s | 512 MB | Judgeable |
| Alarm ClockFor each case, compute how many minutes pass from the current time until the alarm time, rolling over to the next day when needed. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Sub-primeGiven each bank's reserve and a list of debentures between banks, check whether every bank ends with a nonnegative balance after all debentures settle at once. | Easy2 | ArrayImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Dividing NlogôniaGiven a divider point, classify each house coordinate into one of four quadrants or as lying on a dividing line. | Easy2 | ImplementationMath | No attempts yet | 2s | 512 MB | Judgeable |
| Pokemon GOFor each species, compute how many net 10-candy evolutions are possible, sum them, and find the species with the most evolutions. | Easy2 | MathImplementation | No attempts yet | 1s | 32 MB | Judgeable |
| Second Cheapest PresentGiven a list of distinct prices, print the second cheapest one, formatted with two decimal places. | Easy2 | SortingImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| HolesCount the holes in each of N lines of uppercase text, where B counts as two, A D O P Q R count as one, and the rest count as zero. | Easy2 | StringImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Olympic GamesFor each year, decide whether it is a summer Olympic year, and if so whether the games were held, cancelled by a war, or not yet assigned a city. | Easy2 | ImplementationMath | No attempts yet | 2s | 512 MB | Judgeable |
| VirusGiven a key and one line of ciphertext, undo a Caesar variant whose shift grows by one per letter and resets after 25. | Easy2 | StringSimulation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Alpha PuzzleAssign numbers 1 to 26 to letters by scanning the grid and numbering each letter at its first appearance. | Easy2 | SimulationString+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Splitting into Two TeamsGiven four sorted skill levels, split them into two pairs of two and print the smallest possible difference between the two pair sums. | Easy2 | Brute forceMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Farm robot scarecrowCount how many times a robot moving clockwise or counter-clockwise around N stations visits a given station, starting at station 1. | Easy2 | SimulationImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Unit ConversionGiven x of unit A equals y of unit B, convert each listed amount to the other unit and print the result to six decimals. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Magic SquaresGiven a 4x4 grid, check whether all four row sums and all four column sums are equal, then print whether it is magic. | Easy2 | ImplementationMatrix | No attempts yet | 2s | 512 MB | Judgeable |
| FuelConvert fuel consumption from miles per gallon to liters per 100 kilometers using the given conversion constants. | Easy2 | MathImplementation | No attempts yet | 1s | 512 MB | Judgeable |
| Luhn AlgorithmGiven a sixteen-digit card number as a string, check whether it passes the Luhn checksum and print DA or NE. | Easy2 | StringImplementation+2 | No attempts yet | 1s | 512 MB | Judgeable |
| TelephoneFind the base between 2 and 10 whose representation of N has the fewest adjacent digit changes, breaking ties by the largest base. | Easy2 | MathImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Enlarging the Cow SignalPrint an M by N grid of dots and X characters with each cell repeated K times in both directions. | Easy2 | ImplementationArray | No attempts yet | 2s | 512 MB | Judgeable |
| Income taxFor each income, subtract 0, 10 percent, or 20 percent tax depending on whether income is at most 1,000,000, at most 5,000,000, or larger. | Easy2 | ImplementationMath | No attempts yet | 2s | 512 MB | Judgeable |
| Key MakerFor each test case, count how many trash keys have the same cut count and can be deepened, or already match, the customer key. | Easy2 | ArrayImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| GradesGiven a list of grades, compare the midpoint of the maximum and minimum against the overall average, and report whether they differ by less than 1. | Easy2 | ArrayMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Bridge Honor PointsGiven N strings of 13 card characters, add up honor points (A=4, K=3, Q=2, J=1) across all hands and print the total. | Easy2 | ImplementationString+1 | No attempts yet | 1s | 32 MB | Judgeable |
| Sitting (Small)Given a grid of R rows and C columns with R,C at most 5, find the largest set of seats so that no occupied seat has occupied neighbors on both its left and right or both its front and back. | Easy2 | Brute forceImplementation | No attempts yet | 5s | 512 MB | Judgeable |
| Country Leader (Small)For each test case, find the name with the most distinct letters, breaking ties by ASCII alphabetical order, and print it. | Easy2 | StringImplementation+2 | No attempts yet | 5s | 512 MB | Judgeable |
| Country LeaderFor each test case, pick the name with the most distinct letters, breaking ties by lexicographic order where a space sorts before any letter. | Easy2 | StringSorting+2 | No attempts yet | 5s | 512 MB | Judgeable |
| Counting Sheep (Large)For each N, find the first multiple of N that contains all ten digits, or report that no such multiple exists (only N = 0). | Easy2 | MathSimulation+1 | No attempts yet | 5s | 512 MB | Judgeable |
| MicrowaveGiven a start temperature below target, compute total heating time using per-degree rates for frozen and unfrozen states plus a fixed thawing time. | Easy2 | MathImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Refreshment AreaCount the number of D-long horizontal or vertical runs of empty cells in an N by M grid. | Easy2 | ArrayImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| One Hundred to TenParse a ratio written as n:m, divide both numbers by their greatest common divisor, and print the reduced ratio in the same format. | Easy2 | MathNumber theory+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Base 9Convert a given decimal integer between 1 and 10000 into its base 9 representation. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Fibonacci-like SequenceGiven n up to 116, compute the n-th term of the recurrence f(n) = f(n-1) + f(n-3) with f(1)=f(2)=f(3)=1. | Easy2 | Dynamic programmingMath+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Bovine Genomics (Bronze)Count genome positions where the set of characters in spotty cows and the set in plain cows do not overlap. | Easy2 | ImplementationBrute force+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Birthday GraphRead dates in dd mm yyyy form and print a star per birthday for each of the twelve months, in a numbered case format. | Easy2 | ArrayString+1 | No attempts yet | 5s | 512 MB | Judgeable |
| Grid PatternFor each case, print a text grid with pipe, minus, and plus lines and asterisk-filled cells of size w by h. | Easy2 | ImplementationSimulation+1 | No attempts yet | 10s | 512 MB | Judgeable |
| Speed LimitFor each log entry, multiply the speed by the time since the previous entry, sum these products, and print the total distance in miles. | Easy2 | ImplementationMath+1 | No attempts yet | 5s | 512 MB | Judgeable |
| Outer Triangle SumFor each triangle, add the first and last value of every row plus all values of the last row, counting shared corners once, and print the total. | Easy2 | ImplementationArray+2 | No attempts yet | 10s | 512 MB | Judgeable |
| Linear EquationFor each linear equation ax + b = c, decide whether it has no, one, or infinitely many solutions and print the root truncated to six decimals. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| X X gluedFor each registration number, print every run of two or more identical digits in the four-digit group, in left-to-right order. | Easy2 | StringImplementation+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Card Game ContestFor each of N games, Meiji has A_i decks, or gets one basic deck if A_i is 0. Count the number of distinct ways to enter, modulo M. | Easy2 | MathImplementation+2 | No attempts yet | 1s | 256 MB | Judgeable |
| 2017 Yonsei University Programming ContestCount triples (A, B, C) with A+B+C = N, all at least 1, C at least B+2, and A even. | Easy2 | Brute forceMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Hongjun surrounded by fansGiven Hongjun's id, print a 3 by 3 grid of emoticons with :id: in the center and :fan: in the other eight cells. | Easy2 | ImplementationString | No attempts yet | 1s | 64 MB | Judgeable |
| We Lost Again TodayGiven the runs each team scored in all nine innings, decide whether the Ullim Geminis ever held a lead during a game they ended up losing. | Easy2 | ImplementationSimulation+1 | No attempts yet | 1s | 64 MB | Judgeable |
| 2017 Ajou University Programming Contest (Small)Given up to three contestants' scores, submission counts, and last scoring upload times, output the number of the top-ranked contestant by the tie-break rules. | Easy2 | SortingImplementation | No attempts yet | 1s | 512 MB | Judgeable |
| EmpathyMultiply two binary numbers up to 30 bits long and print the product in binary without leading zeros. | Easy2 | MathString+2 | No attempts yet | 2s | 256 MB | Judgeable |
| Jeonbuk National UniversityPrint an ASCII symbol of width N when N is odd, following fixed spacing rules; print "I LOVE CBNU" when N is even. | Easy2 | ImplementationSimulation | No attempts yet | 1s | 128 MB | Judgeable |
| Recovering a Damaged ISBN DigitOne digit of a 13-digit ISBN is replaced by '*', and you print the digit that makes the weighted checksum divisible by 10. | Easy2 | MathImplementation | No attempts yet | 1s | 128 MB | Judgeable |
| I am happy~Given the height N, width M, and a seat number K in row-major order, print the row and column of that seat. | Easy2 | MathImplementation+2 | No attempts yet | 2s | 256 MB | Judgeable |
| Fox SignGiven up to 10 touching pairs among five fingers, decide whether the pattern matches the fox sign: thumb, middle, and ring all touch, while index and little touch nothing. | Easy2 | ImplementationArray | No attempts yet | 0.5s | 512 MB | Judgeable |
| Who Is the Admin?Given nine clubs with N members each, find the club whose best member solved more problems than the best member of every other club. | Easy2 | ImplementationArray+1 | No attempts yet | 1s | 256 MB | Judgeable |
| Credit Card ValidationFor each 16-digit card number, apply the Luhn checksum (double every second digit from the right, sum digits) and print T if the total is divisible by 10, else F. | Easy2 | ImplementationString+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Paint EstimateFor each floor plan, compute the paintable wall and ceiling area minus window and door areas, multiply by the number of apartments, and round the total up by the coverage of one can. | Easy2 | MathImplementation+2 | No attempts yet | 2s | 512 MB | Judgeable |
| Stacking CupsRead each cup's message, recover its radius from either token order, then print colors from smallest to largest cup. | Easy2 | SortingImplementation | No attempts yet | 1s | 512 MB | Judgeable |
| Advertising RevenueFor each data set, sum the payments for every display ad shown and every clickthrough ad clicked, then print the total. | Easy2 | ImplementationSimulation | No attempts yet | 2s | 512 MB | Judgeable |
| UphillRead all integers on one line and print Good if they are in non-decreasing order, otherwise Bad. | Easy2 | ArrayImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Term index in an arithmetic sequenceGiven a first term, a common difference, and a value k, print the 1-based position of k in the arithmetic sequence, or X if k is absent. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Sharing apples and bananasGiven a apples and b bananas, print every common divisor n of a and b with the per-friend apple and banana counts. | Easy2 | MathNumber theory+1 | No attempts yet | 2s | 512 MB | Judgeable |
| Base converterConvert a decimal integer m into base n (2 to 16), using A-F for digits 10 and above. | Easy2 | MathImplementation | No attempts yet | 2s | 512 MB | Judgeable |
| Pepero Day 2017Given a time on November 11, 2017, print the Pepero count from the reward rules based on the hour, minute, and second. | Easy2 | Implementation | No attempts yet | 2s | 512 MB | Judgeable |
| Building a distribution tableGiven real numbers in [0,1), count how many fall into each of m equal-length subintervals and print the counts in order. | Easy2 | ImplementationArray+1 | No attempts yet | 1s | 512 MB | Judgeable |