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 results2,994 problems
| Title | Level | Topics | Solved | Time limit | Memory limit | Judge |
|---|---|---|---|---|---|---|
| Laser Turret MaintenanceGiven a conflict-free n-queens configuration as a column vector, output the eight rotations and reflections in a fixed order with three-character right-justified fields. | Easy3 | ImplementationMatrix+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Car RacingGiven the order in which cars arrive, decide whether a single FIFO bypass lane can reorder them to increasing order. | Easy3 | StackSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Verdis QuoConvert valid Roman numerals to decimal integers using addition and subtraction rules. | Easy3 | StringSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Rout 66Simulate an invader whose strength drops after each stronghold it breaks, processing strongholds nearest first, and report whether all fall. | Easy3 | SimulationSorting+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Queue RearrangementGiven a queue of m items and n simultaneous move operations, apply all moves at once and print the resulting queue order. | Easy3 | ArraySimulation | No attempts yet | 1s | 128 MB | Judgeable |
| Defining MomentFor each word, strip at most one valid prefix and one valid suffix, then substitute the matching English meaning, expanding the suffix after the prefix. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| It's My DerivativeFor each polynomial, print its derivative and the step-by-step evaluation of that derivative at a given x, matching the input's terse notation. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| LRU CachingSimulate an LRU cache over a sequence of letter accesses and exclamation-mark print requests, outputting cache contents from least to most recently used. | Easy3 | Linked listHash map+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Judges' Time CalculationGiven a 12-hour start time and a contest duration, print a lookup table giving the elapsed minutes formula for each hour block. | Easy3 | ImplementationSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Teleporting Firefly ChaseSimulate a chase where the chaser repeatedly teleports a fixed distance toward each firefly flash and is caught if distance drops to 1 or less. | Easy3 | SimulationGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| SteganographyDecode hidden bits from odd/even runs of spaces in a text and decode five-bit groups into characters. | Easy3 | StringBit manipulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Symmetric OrderGiven a list of names sorted by length, rearrange them so shorter names sit at the top and bottom and longer ones in the middle, pairing names from the start. | Easy3 | ArrayImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Flow LayoutPlace rectangles left to right into rows under a max width, wrap when one does not fit, and report the final window width and total height. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Tanning SalonSimulate a tanning salon with a fixed number of beds, tracking arrivals and departures, and count how many customers leave without a bed. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| W's CipherDecrypt messages by extracting each of three character groups and rotating its subsequence right by the matching key. | Easy3 | StringImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Pronounceable PasswordsFor each lowercase password, check three rules: at least one vowel, no three vowels or consonants in a row, and no double letter except ee and oo. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Loansome Car BuyerSimulate monthly depreciation and payments on a car loan, and report the first month when the amount owed drops below the car's value. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Booklet PrintingFor each page count, print which page numbers (or Blank) go on each side of every sheet in fold-over booklet order. | Easy3 | ArrayImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| The SnailSimulate a snail that climbs a bit less each day and slides a fixed distance each night, and report whether it escapes or falls back first. | Easy3 | ImplementationSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Polynomial ShowdownGiven nine polynomial coefficients from degree 8 down to the constant, print each polynomial with signs, exponents, and coefficients formatted to drop all unnecessary characters. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| SemigroupsGiven a small multiplication table, decide whether it defines a semigroup, report the first counterexample if not, and check commutativity. | Easy3 | Brute forceImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Basically SpeakingConvert a number from one base to another (bases 2 to 16) and print the result right-justified in a 7-character field, or ERROR if it exceeds 7 digits. | Easy3 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Take Your VitaminsFor each line of amount, unit, requirement, and name, print the rounded daily-value percentage; collect items under 1% into a trailing list. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Spelling BeRead a dictionary and several emails, then report for each email whether all its words are known and list the unknown words in order. | Easy3 | Hash mapString+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Counting PagesGiven a document's page count and a comma-separated list of page ranges, count the distinct pages that are actually printed, ignoring empty ranges and pages past the end. | Easy3 | ImplementationString+2 | No attempts yet | 1s | 256 MB | Judgeable |
| Post OfficeSort each item's three dimensions into length, height, and thickness, then apply the postal size rules to print one of four classes. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| DanceCheck a sequence of dance steps against five textual rules and report which rules it violates, uppercasing any misplaced dip. | Easy3 | ImplementationString+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Primorial Number SystemRepresent each positive integer in the mixed-radix primorial system where the i-th place value is the product of the first i primes. | Easy3 | MathNumber theory+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Wavelet CompressionGiven a signal transformed by recursive sum/difference wavelet steps, reconstruct the original samples for each test case. | Easy3 | Divide and conquerSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Bridge BiddingFor each 13-card bridge hand, compute high card points and suit lengths, then print the first applicable opening bid rule. | Easy3 | ImplementationSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Gold CoinsFor each number of days, add up the gold coins when the knight is paid N coins on each of N consecutive days. | Easy3 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| GymGiven an N by N matrix of card counts, compute the probability distribution over N baskets for the first 10 steps of a Markov process starting at basket 1. | Easy3 | MathMatrix+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Tetromino Maximum SumGiven an N x N grid of integers, place one of the five tetrominoes (with rotations, not flips) so the four covered cells have the largest sum. | Easy3 | Brute forceImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| The Great SaharaOn a fixed 54-triangle hex board, decide whether player one can move one pyramid to trap an opponent's pyramid immediately. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Hanafuda ShuffleCards 1 to n start from the bottom, and each cut moves a contiguous block of c cards starting at position p to the top; report the top card after all cuts. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Carbonated DrinksGiven starting empties, empties found, and the empties needed per exchange, count how many drinks Junmin can obtain and drink in total. | Easy3 | MathSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| When Do We Finish?Add each event's duration to its start time and print the resulting clock time, appending the number of days past midnight when the end crosses into later days. | Easy3 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Car ParkSimulate a sequence of car entry and exit signals for a car park of capacity S starting with C cars, stopping early if an exit occurs while empty. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Street NumbersCount how many times each digit 0 to 9 appears on house numbers from L to H, skipping the given gap ranges. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Hostel NightsFor each week, apply five nights of elimination rules to 20 rooms and list the students who survive the most nights, ordered by room number. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Air Old ZeelandFor each customer, sum the prices of requested products whose shipping delay fits the wait limit, flag customers who miss any product, and count them. | Easy3 | ImplementationArray+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Postman JoeSimulate Joe's walk on 20 houses, flag any out-of-range or repeated house as illegal, else list the houses with no delivery. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Driving the RoverSimulate a rover that takes one command per second, tracking its speed, heading, and position, then report the final integer coordinates. | Easy3 | SimulationImplementation | No attempts yet | 1s | 128 MB | Judgeable |
| CountdownGiven a Maya Long Count date and its Julian Day Number, convert today's Gregorian date to JDN and report the days until 13.0.0.0.0. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Grocery ShoppingFor each grocery item, find its matching store item by case-insensitive name and add the club-card saving on the units actually bought. | Easy3 | Hash mapString+1 | No attempts yet | 1s | 128 MB | Judgeable |
| LobbyingSum each lawmaker's donations made within 1000 days before the vote, then weight each no vote by 1/(1+D/10000) and add up both sides. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Sand CastlesGiven a rectangular patch, a perimeter moat, and cylindrical towers, compute how much the flat base level rises or falls so the sand volume stays fixed. | Easy3 | GeometryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Global WarmingGiven a small land/sea grid, mark every land cell with three or more sea neighbours as sea simultaneously, then print the tight bounding box of the remaining land. | Easy3 | ArraySimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Base KConvert each n to base k and report whether every digit from 0 to k-1 appears, formatting the output line exactly as specified. | Easy3 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Dividing the Pirate HoardEach of N pirates in turn splits the pile into N equal parts, keeps one part plus the remainder, and returns the rest; report each pirate's hidden coins and the leftover pile. | Easy3 | SimulationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Parity BitSplit each line into 8-bit blocks, check whether the parity bit matches the parity of the first 7 bits, and count the mismatches. | Easy3 | ImplementationString+2 | No attempts yet | 1s | 128 MB | Judgeable |
| DecoderEach word contributes one letter: the first letter of the first word, then the k-th letter of each word where k is the previous word's length; spaces appear when the previous word is too long. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| POIEach problem's value is the count of contestants who missed it; report Philip's total score and his rank using the four tiebreak terms. | Easy3 | ImplementationArray+2 | No attempts yet | 1s | 256 MB | Judgeable |
| UniqueFor each of three rounds, a player scores the number written only if no one else wrote it, and totals are printed in input order. | Easy3 | ArrayHash map+1 | No attempts yet | 1s | 128 MB | Judgeable |
| The TravelerGiven gaps between n towns and a walk of m east/west jumps, find the total distance covered, reported mod 100000. | Easy3 | Prefix sumArray+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Card Captor SanggeunSimulate a two-player card game where each player always plays the smallest legal card, and report the final scores. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Card RearrangementStarting from the stack 1, 2, ..., 2n, apply a sequence of cuts and riffle shuffles and print the final order of the cards. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Look-and-Say StringApply the look-and-say run-length encoding to a digit string n times and print the resulting string. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Rolling a DieSimulate rolling a die through a list of moves and sum the top face value after each move. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Calculator ProgramRead alternating numbers and operators, evaluate left to right ignoring precedence, and print the value when = appears. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Longest WordScan text until the token E-N-D, split it into words made of letters and hyphens, and print the longest such word in lowercase, breaking ties by first occurrence. | Easy3 | StringImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| In BrailleTranslate a string of digits to Braille cells, or three lines of Braille cells back to digits, using the fixed digit-to-cell table. | Easy3 | StringHash map+2 | No attempts yet | 1s | 128 MB | Judgeable |
| ElectricityGiven dated meter readings sorted by date, count pairs on consecutive calendar days and report how many such days exist plus the total consumption between them. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Bad Random NumbersSimulate the middle-square method from N and count generated values up to and including the first repeat. | Easy3 | SimulationHash map | No attempts yet | 1s | 128 MB | Judgeable |
| A Spiral WalkFill an N by N grid with the visit order of a clockwise spiral that starts at the top-left and ends near the center. | Easy3 | SimulationMatrix+1 | No attempts yet | 1s | 128 MB | Judgeable |
| The Robot PlowGiven up to 200 axis-aligned rectangles on a grid at most 240 by 240, count the number of unit squares covered by at least one rectangle. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Invasion of the MilkweedSpread milkweed from a start cell to all eight neighbors each week and report the week it covers the last non-boulder cell. | Easy3 | BFSGraph+2 | No attempts yet | 1s | 128 MB | Judgeable |
| The Rock GamePrint the reflected binary Gray code cycle for N bits as 2^N + 1 lines, each line showing X for covered holes and O for uncovered ones. | Easy3 | Bit manipulationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| SuperlativesGiven expected rain E and actual rain A, print how many times the word mega precedes drought based on the ratio E/A, or no drought if E <= A. | Easy3 | ImplementationMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Best GrassCount clumps of # cells in a grid, where each clump is one cell or two orthogonally adjacent cells and different clumps never touch. | Easy3 | ArraySimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Another Cow Number GameStarting from N, repeatedly apply the Collatz rule (3N+1 if odd, N/2 if even) and count the steps until N reaches 1. | Easy3 | SimulationMath+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Serious Cow TagSimulate the elimination game where each active cow tags her nearest remaining cow, and report the last cow standing. | Easy3 | SimulationGeometry+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Mileage BankEach line gives a flight's distance and cabin class; sum the ACMPerk miles earned per flight, with bonuses for B and F and a 500 mile floor for Y. | Easy3 | MathImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Balloon GameGiven N slots and Q arithmetic progressions, mark the slots each pass would fill (skipping already filled ones), then count the empty slots. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Encrypted SMSEach encrypted letter was shifted forward within its phone keypad key by its 1-based position; given the ciphertext, recover the original password. | Easy3 | StringSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Blowing FusesSimulate toggling devices on and off, tracking the running total power and whether it ever exceeds the fuse capacity. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| There's treasure everywhere!Parse a map of step counts and compass directions, compute the treasure's coordinates, and print the straight-line distance from the origin. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Carbon DatingGiven sample carbon mass and hourly decays, estimate age from the half-life decay formula, then round to 100 or 1000 years depending on size. | Easy3 | MathImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| URLsParse each URL into protocol, host, optional port, and optional path, printing <default> for missing components. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Definite ValuesProcess a sequence of single-letter assignments, starting with only 'a' defined, and after each program part print the defined variables in alphabetical order. | Easy3 | SimulationHash map+1 | No attempts yet | 1s | 128 MB | Judgeable |
| S-TreesGiven an S-tree's variable ordering and terminal labels, evaluate the Boolean function for each supplied variable assignment. | Easy3 | TreeSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Four QuartersFor each round count from 1 to 20, compute the probability that A wins, B wins, or the game ties after that many rounds of this four-coin game. | Easy3 | ProbabilityDynamic programming+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Bode PlotGiven source voltage, resistance, capacitance, and several angular frequencies, compute the resistor voltage magnitude from the RC low-pass circuit equations. | Easy3 | MathSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Set MeGiven tableaus of Set cards, print each tableau and then every triple of cards that forms a valid set, in index order. | Easy3 | Brute forceImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Clock PatienceSimulate Clock Patience on several decks: deal cards into 13 piles, flip cards following rank-to-pile moves, and report how many cards were exposed and the last card. | Easy3 | SimulationArray+1 | No attempts yet | 1s | 128 MB | Judgeable |
| FloppiesCompute the number of floppies by applying fixed roundings for compression, uuencoding, 30000-line splitting, and recompression. | Easy3 | MathSimulation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Transaction ProcessingRead ledger accounts and transaction entries, then print an exception report for any transaction whose debits and credits do not sum to zero. | Easy3 | ImplementationHash map+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Adam's GenesProcess cloning requests in order, tracking each clone's accumulated genes and reporting whether it is consistent and safe, disconnected from Adam, or doubly mutated. | Easy3 | Hash mapSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Uniform GeneratorFor each pair STEP and MOD, decide whether seed(x+1) = (seed(x) + STEP) mod MOD cycles through all MOD values, which holds exactly when gcd(STEP, MOD) = 1. | Easy3 | Number theoryMath+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Unix ls Column FormattingSort filenames by ASCII value and lay them out in column-major order with fixed-width padding, as few rows as fit in 60 characters. | Easy3 | SortingImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Factorial FrequenciesRead n values until a terminating 0, and for each n count how many times each digit 0 through 9 appears in the decimal representation of n! (n up to 366), printing the counts in a fixed two-line format. | Easy3 | MathImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Evaluating Simple C ExpressionsEvaluate a sequence of simple C expressions with +, -, and prefix or postfix ++/--, printing the expression value and the final values of used variables. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| EdgeGiven a string of A (clockwise) and V (counter-clockwise) turns, emit PostScript line commands tracing a unit-step path from a fixed start point. | Easy3 | SimulationImplementation+1 | No attempts yet | 1s | 128 MB | Judgeable |
| Average is not Fast Enough!Parse each team's section times in h:mm:ss form, sum them, and print the average seconds per kilometer rounded to the nearest second, or a dash if any runner was disqualified. | Easy3 | ImplementationString+2 | No attempts yet | 1s | 128 MB | Judgeable |
| HTMLRender an HTML fragment of plain text with <br> and <hr> tags, wrapping lines at 80 characters. | Easy3 | StringImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Mosquito MultiplicationSimulate weekly mosquito stages (eggs become larvae, larvae become pupae, pupae become adults) with floor divisions and report the adult count after N Sundays. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| On-Line BankingSimulate a stream of bank commands (create, deposit, withdraw, transfer) over many scenarios and print the result of each request. | Easy3 | SimulationImplementation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Read the ChessboardGiven an ASCII-art chessboard, list each side's pieces in standard notation, grouped by type in a fixed order and sorted by position rules. | Easy3 | ImplementationString+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Bridge HandsDeal a 52-card deck to four bridge players from a given dealer, sort each 13-card hand by suit and rank, and print the hands in a fixed card-table format. | Easy3 | ImplementationSimulation+2 | No attempts yet | 1s | 128 MB | Judgeable |
| Complicated RouteParse a route of step counts in eight compass directions, sum the displacement, and print the final point and its distance from the origin to three decimals. | Easy3 | ImplementationMath+2 | No attempts yet | 1s | 128 MB | Judgeable |