Use these filters to narrow down your next problem to solve:
OJ: , Topic: , Quality:
You can now sort these problems based on Distinct ACcepted Users (DACU) column.
Generally, problems with high DACU are the easier problems.
Note that we only update DACU column manually when we first entered the hint (thus an outdated data).
As Kattis users, you can also sort these problems based Kattis points (usually correlated with DACU but not always).
Generally, problems with low Kattis points are the easier problems.
Note that we only update Point column manually (not a live data).
For Kattis and Google Chrome users, install Kattis Hint Giver created by one of my student Lin Si Jie that integrates this page directly with Kattis problems pages (Kattis has major UI/UX upgrade on early Jun 2022, Si Jie has updated this tool and added 'spoiler blur' so users can decide when to be spoiled; but Kattis changes its UI again by end 2023 so this feature is now broken again)
(Almost) all of the easiest 1097 problems (range: [1.1..3.3] points, average at 2.2 points) have hints and solving them all gives you 1097*~2.2 ≥ 2413.4 total Kattis points — The Lower Bound of Programming Contests in the 2020s year 2024.
Tips: You may want to occasionally 'Remove 'Kattis Hint Giver' from Chrome' and re-'Add it back to Chrome' to manually sync this Methods to Solve content with the local cache.
Kattis | Problem Title | CP4 | Hint | DACU | Point |
---|---|---|---|---|---|
baloni | baloni | 2.2a, 1D Array, Medium | clever use of 1D histogram array to decompose the shots as per requirement | 689 | 3.5 |
downtime | downtime | 2.2a, 1D Array, Medium | 1D array; use Fenwick Tree-like operation for Range Update Point Query | 1068 | 3.2 |
erase | erase | 2.2a, 1D Array, Medium | if N is odd, the second line has to be the inverse of the first; if N is even, both lines have to be the same | 2166 | 1.6 |
fluortanten | fluortanten | 2.2a, 1D Array, Medium | remove Bjorn first; then do O(n) pass to check where is Bjorn's optimal position | 181 | 3.1 |
greedilyincreasing | greedilyincreasing | 2.2a, 1D Array, Medium | just 1D array manipulation; this is not the DP-LIS problem | 1151 | 1.9 |
jollyjumpers | jollyjumpers | 2.2a, 1D Array, Medium | 1D Boolean flags to check [1..n-1]; also available at UVa 10038 - Jolly Jumpers | 413 | 3.4 |
rankproblem | rankproblem | 2.2a, 1D Array, Medium | list (array) manipulation problem | 120 | 2.8 |
trackingshares | trackingshares | 2.2a, 1D Array, Medium | keep track of the shares in small arrays and simulate | 73 | 2.2 |
astro | astro | 2.2b, 1D Array, Harder | use large Boolean array | 115 | 4.3 |
charged | charged | 2.2b, 1D Array, Harder | convoluted problem statement; ignore E and F; for each cell, compute sum of Vs using rx/ry; convert the value of each ce... | 61 | 1.8 |
crashingrobots | crashingrobots | 2.2b, 1D Array, Harder | just simulate the x/y/direction of the N robots | 107 | 4.6 |
divideby100 | divideby100 | 2.2b, 1D Array, Harder | big 1D character array processing; be careful | 557 | 4.2 |
flippingpatties | flippingpatties | 2.2b, 1D Array, Harder | use 1D int array of size 43 201; at each time t, we need one cook (hand) at time t-2d (to start), t-d (to flip), ... | 116 | 2.4 |
inverteddeck | inverteddeck | 2.2b, 1D Array, Harder | can we sort the array with just one contiguous swap?; compress duplicates; use sentinel so that we only check /&bsol... | 203 | 3.7 |
keypad | keypad | 2.2b, 1D Array, Harder | 2D array manipulation | 200 | 3.3 |
mastermind | mastermind | 2.2b, 1D Array, Harder | 1D array manipulation to count r and s | 446 | 2.4 |
physicalmusic | physicalmusic | 2.2b, 1D Array, Harder | a reading comprehension problem to come up with a simple algorithm to determine the answer | 168 | 5.5 |
piperotation | piperotation | 2.2b, 1D Array, Harder | use 1D Boolean array to check if cell (r, c) needs to be connected from the top (r-1) or left (c-1) and pass information... | 50 | 2.6 |
pivot | pivot | 2.2b, 1D Array, Harder | static range min/max query problem; special condition allows this problem to be solvable in O(n) using help of 1D arrays | 1723 | 3.2 |
queens | queens | 2.2b, 1D Array, Harder | simple N queens verifier program; use several 1D Boolean arrays to help do this check in O(N) | 725 | 3.3 |
rockband | rockband | 2.2b, 1D Array, Harder | interesting usage of 1D array to simplify the solution; a bit of sorting to arrange the output | 194 | 3.9 |
traffic | traffic | 2.2b, 1D Array, Harder | just simulate the movement of the car for 'longer than 10^6', analyze the required bound | 233 | 4.1 |
upsanddownsofinvesting | upsanddownsofinvesting | 2.2b, 1D Array, Harder | simplify by a factor of two by realizing that peaks and valleys are symmetrical | 147 | 3.6 |
compromise | compromise | 2.2c, 2D Array, Easier | 2D array manipulation; take the majority bits of each column; output either 0 or 1 for ties | 363 | 2.2 |
epigdanceoff | epigdanceoff | 2.2c, 2D Array, Easier | count number of CCs on 2D grid; simpler solution exists: count the number of blank columns plus one | 505 | 1.9 |
fastestavailableroute | fastestavailableroute | 2.2c, 2D Array, Easier | count the number of dots in a 2D grid; scale up by a factor of s | 126 | 2.5 |
flowshop | flowshop | 2.2c, 2D Array, Easier | interesting 2D array manipulation | 392 | 2.5 |
guesswho | guesswho | 2.2c, 2D Array, Easier | 2D and 1D array; simulate and eliminate impossible candidates | 197 | 1.6 |
imageprocessing | imageprocessing | 2.2c, 2D Array, Easier | interesting 2D array manipulation | 344 | 2.1 |
laegdyfirlandinu | laegdyfirlandinu | 2.2c, 2D Array, Easier | easy 2D array check | 208 | 1.6 |
laptopstickers | laptopstickers | 2.2c, 2D Array, Easier | 2D array manipulation | 318 | 2.5 |
moderatepace | moderatepace | 2.2c, 2D Array, Easier | sort each column; take the middle one | 272 | 1.6 |
mylla2 | mylla2 | 2.2c, 2D Array, Easier | simple 3x3 grid manipulation | 247 | 1.6 |
nineknights | nineknights | 2.2c, 2D Array, Easier | 2D array checks; 8 directions | 881 | 1.9 |
patchwork | patchwork | 2.2c, 2D Array, Easier | tedious 2D grid manipulation | 109 | 2.0 |
prjonamynstur | prjonamynstur | 2.2c, 2D Array, Easier | process-2d-grid-on-the-fly | 395 | 1.5 |
rulen | rulen | 2.2c, 2D Array, Easier | bitmask application; follow the instructions | 59 | 2.9 |
starbattles1 | starbattles1 | 2.2c, 2D Array, Easier | simple 2D array checks; use delta row/col technique to simplify the implementation | 189 | 3.1 |
thisaintyourgrandpascheckerboard | thisaintyourgrandpaschecke... | 2.2c, 2D Array, Easier | simple 2D array manipulation | 578 | 1.6 |
vemvinner | vemvinner | 2.2c, 2D Array, Easier | small 3x3 array checks | 408 | 2.1 |
2048 | 2048 | 2.2d, 2D Array, Harder | just a 2D array manipulation problem; utilize symmetry using 90 degrees rotation(s) to reduce 4 cases into 1 | 3150 | 2.1 |
apples | apples | 2.2d, 2D Array, Harder | 2D array manipulation; gravity simulation | 439 | 3.6 |
falcondive | falcondive | 2.2d, 2D Array, Harder | 2D array manipulation; translation vector of the Falcon | 64 | 2.8 |
flagquiz | flagquiz | 2.2d, 2D Array, Harder | array of array of strings; be careful; duplicates may exists | 167 | 3.7 |
funhouse | funhouse | 2.2d, 2D Array, Harder | 2D array manipulation; note the direction update | 700 | 2.0 |
huntthewumpus | huntthewumpus | 2.2d, 2D Array, Harder | tedious 2D array simulation | 215 | 2.2 |
prva | prva | 2.2d, 2D Array, Harder | 2D array manipulation; check vertically and horizontally | 756 | 1.7 |
rings2 | rings2 | 2.2d, 2D Array, Harder | more challenging 2D array manipulation; special output formatting style | 385 | 3.8 |
tetris | tetris | 2.2d, 2D Array, Harder | actually 3D pattern array to simulate various shape positions | 322 | 1.8 |
waterworld | waterworld | 2.2d, 2D Array, Harder | reading comprehension problem; compute average of a 2D array | 68 | 2.2 |
basicprogramming2 | basicprogramming2 | 2.2e, Sorting, Easier | a nice problem about basic sorting applications | 189 | 3.4 |
classfieldtrip | classfieldtrip | 2.2e, Sorting, Easier | just sort the characters | 1019 | 1.3 |
closingtheloop | closingtheloop | 2.2e, Sorting, Easier | sort first | 1415 | 1.6 |
cups | cups | 2.2e, Sorting, Easier | a bit of string parsing; sort | 2987 | 1.5 |
height | height | 2.2e, Sorting, Easier | insertion sort simulation | 899 | 2.0 |
judging | judging | 2.2e, Sorting, Easier | sort DOM judge and Kattis outputs; then do the O(n) merge procedure of mergesort to count common outputs | 1183 | 2.5 |
magictrick | magictrick | 2.2e, Sorting, Easier | can if all chars are unique or cannot otherwise; either sort s then check adjacent characters or use set to eliminate du... | 1605 | 1.3 |
mjehuric | mjehuric | 2.2e, Sorting, Easier | a direct simulation of a bubble sort algorithm | 1349 | 1.6 |
musicaltrees | musicaltrees | 2.2e, Sorting, Easier | sort p and t; then just simulate as asked with Boolean array | 23 | 2.8 |
nothanks | nothanks | 2.2e, Sorting, Easier | sort; then linear pass to check adjacent sorted elements | 441 | 2.4 |
sidewayssorting | sidewayssorting | 2.2e, Sorting, Easier | stable_sort or sort multi-fields of columns of a 2D array; ignore case | 857 | 2.0 |
stokigalistor | stokigalistor | 2.2e, Sorting, Easier | compare original list with its sorted version | 537 | 2.2 |
addemup | addemup | 2.2f, Sorting, Harder | create a helper function to read digits upside down; add all possibilities; sort; then use fast O(n) target pair solutio... | 338 | 4.4 |
booking | booking | 2.2f, Sorting, Harder | 2 events per booking (need room and release room); convert to minutes; be careful of leap year on 2016; sort the events;... | 164 | 5.4 |
chartingprogress | chartingprogress | 2.2f, Sorting, Harder | sort using modified comparison function (by column); transpose the input | 757 | 2.2 |
classy | classy | 2.2f, Sorting, Harder | sort using modified comparison function; a bit of string parsing/tokenization | 1633 | 4.5 |
dirtydriving | dirtydriving | 2.2f, Sorting, Harder | sort; find max - derive the formula; reading comprehension problem | 279 | 2.1 |
dyslectionary | dyslectionary | 2.2f, Sorting, Harder | sort the reverse of original string; output formatting | 775 | 3.4 |
gearchanging | gearchanging | 2.2f, Sorting, Harder | generate all O(N*M) possible gear ratios; sort; check consecutive ratios (it is ok to have duplicates) | 161 | 3.2 |
includescoring | includescoring | 2.2f, Sorting, Harder | sort; custom comparison function, tedious | 342 | 3.7 |
lawnmower | lawnmower | 2.2f, Sorting, Harder | sort and check if Guido covers all land (end-to-end and side-to-side); also available at UVa 12269 - Land Mower | 448 | 2.1 |
longswaps | longswaps | 2.2f, Sorting, Harder | observation: if k ≤ n/2, output 'Yes'; otherwise the middle chars at s[n-k..k-1] cannot move; sort s and compare the ... | 172 | 3.3 |
musicyourway | musicyourway | 2.2f, Sorting, Harder | stable_sort; custom comparison function | 404 | 2.4 |
sortofsorting | sortofsorting | 2.2f, Sorting, Harder | stable_sort or sort multi-fields | 2667 | 2.2 |
statues | statues | 2.2f, Sorting, Harder | sort distinct statue heights; test all 4 possible diagonal placements, pick the min | 106 | 2.8 |
zipfsong | zipfsong | 2.2f, Sorting, Harder | sort; custom comparison function; zipf law | 209 | 4.5 |
bread | bread | 2.2g, Special Sorting | inversion count; hard to derive | 249 | 5.0 |
excursion | excursion | 2.2g, Special Sorting | inversion index; requires O(n log n) merge sort | 387 | 4.3 |
froshweek | froshweek | 2.2g, Special Sorting | requires O(n log n) merge sort; 64-bit integer; also available at UVa 11858 - Frosh Week | 694 | 5.6 |
gamenight | gamenight | 2.2g, Special Sorting | Counting Sort is a subproblem; count frequency of A/B/Cs; complete search AA..ABB..BCC..C or AA..ACC..CBB..B | 70 | 2.8 |
mali | mali | 2.2g, Special Sorting | Counting Sort two arrays; greedy matching largest+smallest at that point | 97 | 5.1 |
sort | sort | 2.2g, Special Sorting | Counting Sort variant | 318 | 2.3 |
ultraquicksort | ultraquicksort | 2.2g, Special Sorting | requires O(n log n) merge sort; also available at UVa 10810 - Ultra Quicksort | 180 | 5.2 |
bracketmatching | bracketmatching | 2.2j, Stack | bracket matching; stack | 1172 | 1.7 |
dream | dream | 2.2j, Stack | stack simulation; reading comprehension problem, need other fast DS for mapping strings to indices | 219 | 6.4 |
evenup | evenup | 2.2j, Stack | use stack to solve this problem | 1273 | 2.7 |
pairingsocks | pairingsocks | 2.2j, Stack | simulation using two stacks; just do as asked | 556 | 3.0 |
restaurant | restaurant | 2.2j, Stack | simulation with stack-based concept; drop plates at stack 2 (LIFO); use move 2-$gt;1 to reverse order; take from stack 1... | 364 | 4.5 |
reversebinary | reversebinary | 2.2j, Stack | decimal to binary; reverse it; binary to decimal | 7144 | 1.5 |
symmetricorder | symmetricorder | 2.2j, Stack | use stack to help reverse even-indexed names | 3584 | 1.5 |
thegrandadventure | thegrandadventure | 2.2j, Stack | stack simulation | 348 | 2.0 |
throwns | throwns | 2.2j, Stack | use stack of egg positions to help with the undo operation; be careful of corner cases involving modulo operation | 1091 | 2.6 |
bracketsequence | bracketsequence | 2.2k, Stack-based Problems | bracket matching variant; stack; push a pair of (+ result, * result) for each '('; pop topmost pair for each ')'; operat... | 100 | 5.5 |
bungeebuilder | bungeebuilder | 2.2k, Stack-based Problems | clever usage of stack; linear pass; bracket (mountain) matching variant | 83 | 3.3 |
circuitmath | circuitmath | 2.2k, Stack-based Problems | postfix calculator problem | 918 | 2.4 |
delimitersoup | delimitersoup | 2.2k, Stack-based Problems | bracket matching; stack | 382 | 1.9 |
backspace | backspace | 2.2l, List/Queue/Deque | we can use deque (or vector) to help solve this problem | 2517 | 3.0 |
ferryloading3 | ferryloading3 | 2.2l, List/Queue/Deque | simulation with queue; also available at UVa 10901 - Ferry Loading III | 368 | 3.6 |
ferryloading4 | ferryloading4 | 2.2l, List/Queue/Deque | simulation with queue; also available at UVa 11034 - Ferry Loading IV | 703 | 3.6 |
foosball | foosball | 2.2l, List/Queue/Deque | queue simulation; tedious | 186 | 3.7 |
integerlists | integerlists | 2.2l, List/Queue/Deque | use deque for fast deletion from front (normal) & back (reversed list); use stack to reverse the final list if it is... | 882 | 4.8 |
joinstrings | joinstrings | 2.2l, List/Queue/Deque | all '+' operations must be O(1) | 959 | 4.1 |
lyklagangriti | lyklagangriti | 2.2l, List/Queue/Deque | use list and its iterator; very similar to Kattis - sim | 114 | 2.7 |
server | server | 2.2l, List/Queue/Deque | one first come first serve pass; we can use queue although overkill | 3331 | 1.9 |
sim | sim | 2.2l, List/Queue/Deque | use list and its iterator | 99 | 2.0 |
teque | teque | 2.2l, List/Queue/Deque | all operations must be O(1) | 766 | 3.3 |
trendingtopic | trendingtopic | 2.2l, List/Queue/Deque | use queue of length 7 to maintain words in the past 7 days, unordered_map to count frequencies, sort to format the outpu... | 181 | 5.8 |
alehouse | alehouse | 2.3a, Priority Queue | discretize the events; PQ simulation | 223 | 4.6 |
clinic | clinic | 2.3a, Priority Queue | interesting PQ simulation; reverse thinking; project to time 0 | 165 | 3.0 |
guessthedatastructure | guessthedatastructure | 2.3a, Priority Queue | stack, queue, and priority_queue; also available at UVa 11995 - I Can Guess ... | 2148 | 2.5 |
heap | heap | 2.3a, Priority Queue | basic Binary (Max) Heap implementation task | 11 | 5.8 |
janeeyre | janeeyre | 2.3a, Priority Queue | simulate Anna's reading behavior with PQ; the input parsing is tedious | 79 | 4.8 |
jugglingpatterns | jugglingpatterns | 2.3a, Priority Queue | PQ simulation; reading comprehension | 48 | 6.3 |
knigsoftheforest | knigsoftheforest | 2.3a, Priority Queue | PQ simulation after sorting the entries by year | 184 | 3.6 |
numbertree | numbertree | 2.3a, Priority Queue | not a direct priority queue problem, but the indexing strategy is similar to binary heap indexing | 1760 | 2.1 |
pharmacy | pharmacy | 2.3a, Priority Queue | simulation with PQ (time) and 2 normal queues (in-store vs remote) | 118 | 3.4 |
rationalsequence2 | rationalsequence2 | 2.3a, Priority Queue | the L/R pattern can be easily derived and indexing strategy is similar to binary heap indexing | 1388 | 1.5 |
rationalsequence3 | rationalsequence3 | 2.3a, Priority Queue | the reverse problem of rationalsequence2 | 587 | 1.8 |
stockprices | stockprices | 2.3a, Priority Queue | PQ simulation; both max and min PQ | 109 | 3.7 |
alphabetspam | alphabetspam | 2.3b, DAT, ASCII | count the frequencies of lowercase, uppercase, and whitespace characters | 3902 | 1.4 |
cyclicalperiods | cyclicalperiods | 2.3b, DAT, ASCII | DAT of last occurrence of 26 chars [`a`..`z`], keep the running max | 112 | 3.0 |
keyboardd | keyboardd | 2.3b, DAT, ASCII | frequency counting of A-Zs and spaces | 92 | 2.0 |
quickbrownfox | quickbrownfox | 2.3b, DAT, ASCII | pangram; frequency counting of 26 alphabets | 4433 | 1.6 |
soundex | soundex | 2.3b, DAT, ASCII | DAT for soundex A-Z code mapping; also available at UVa 10260 - Soundex | 106 | 2.9 |
bladra | bladra | 2.3c, DAT, Others | DAT of frequencies of size k; find min | 324 | 2.0 |
bookingaroom | bookingaroom | 2.3c, DAT, Others | only 100 rooms; use 1D Boolean array | 2849 | 1.7 |
busnumbers | busnumbers | 2.3c, DAT, Others | only 1000 bus numbers; use 1D Boolean array | 2776 | 2.4 |
dontbefake | dontbefake | 2.3c, DAT, Others | it is sufficient to use DAT of size 86400 to get the required answers efficiently | 100 | 2.9 |
freefood | freefood | 2.3c, DAT, Others | only 365 days in a year | 1965 | 1.5 |
hardware | hardware | 2.3c, DAT, Others | parsing is tedious; count the frequency of digits | 244 | 2.0 |
heimavinna | heimavinna | 2.3c, DAT, Others | DAT of 1000 problems | 431 | 1.4 |
princesspeach | princesspeach | 2.3c, DAT, Others | DAT; linear pass | 839 | 2.1 |
relocation | relocation | 2.3c, DAT, Others | just use DAT | 1112 | 1.5 |
simone | simone | 2.3c, DAT, Others | DAT to count frequencies of [1..K] | 106 | 1.6 |
bard | bard | 2.3d, Hash Table (set) | use one unordered_set per villager; simulate the singing process | 637 | 2.6 |
boatparts | boatparts | 2.3d, Hash Table (set) | use unordered_set | 1398 | 1.6 |
cd | cd | 2.3d, Hash Table (set) | unordered_set is faster than set here; or use modified merge as the input is sorted; also available at UVa 11849 - CD | 3176 | 5.3 |
deduplicatingfiles | deduplicatingfiles | 2.3d, Hash Table (set) | use vector to store the strings; unordered_set to store unique strings; and complete search to compare the n^2 hash code... | 583 | 4.4 |
engineeringenglish | engineeringenglish | 2.3d, Hash Table (set) | use unordered_set to remember duplicated words; transform to lowercase | 1627 | 2.2 |
esej | esej | 2.3d, Hash Table (set) | use unordered_set to prevent duplicate | 509 | 3.3 |
everywhere | everywhere | 2.3d, Hash Table (set) | use unordered_set | 7015 | 1.4 |
greetingcard | greetingcard | 2.3d, Hash Table (set) | use unordered_set; good question; major hint: only 12 neighbors | 607 | 4.9 |
icpcawards | icpcawards | 2.3d, Hash Table (set) | use unordered_set; print first 12 distinct Universities (and their first teams) | 2167 | 1.4 |
icpcrecordmatching | icpcrecordmatching | 2.3d, Hash Table (set) | string processing; set of emails/names; sort the output | 111 | 4.2 |
iwannabe | iwannabe | 2.3d, Hash Table (set) | sort Pokenoms based on each stat; pick top K ids and put in an unordered_set; report final size of unordered_set | 739 | 2.5 |
keywords | keywords | 2.3d, Hash Table (set) | pre-process the strings; put inside unordered_set; report final size | 349 | 2.3 |
knotknowledge | knotknowledge | 2.3d, Hash Table (set) | simple set difference problem | 890 | 1.5 |
nodup | nodup | 2.3d, Hash Table (set) | use unordered_set; string | 3564 | 1.3 |
oddmanout | oddmanout | 2.3d, Hash Table (set) | use unordered_set to find and eliminate pairs | 4450 | 1.5 |
pizzahawaii | pizzahawaii | 2.3d, Hash Table (set) | use Python to help with (unordered) set intersection and difference operations | 335 | 2.6 |
proofs | proofs | 2.3d, Hash Table (set) | parsing; use unordered_set to store past conclusions; a few corner cases | 48 | 2.4 |
securedoors | securedoors | 2.3d, Hash Table (set) | use unordered_set to keep track of the people | 2108 | 1.8 |
shiritori | shiritori | 2.3d, Hash Table (set) | linear pass; use unordered_set to keep track of words that have been called | 295 | 2.9 |
shoppinglist | shoppinglist | 2.3d, Hash Table (set) | simple set intersection problem | 16 | 4.4 |
shoppinglisteasy | shoppinglisteasy | 2.3d, Hash Table (set) | see Kattis - shoppinglist | 23 | 3.4 |
thoringtest | thoringtest | 2.3d, Hash Table (set) | lowercase all inputs; see if all words are known by Thore; use set | 38 | 2.8 |
tripodometer | tripodometer | 2.3d, Hash Table (set) | let s = sum(d); subtract s by each d_i; keep the answers in a set; sort | 185 | 2.1 |
upprodun | upprodun | 2.3d, Hash Table (set) | not really a Hash Table problem but uses Hash Table concept; the number of teams in each room is the 'load factor' of th... | 197 | 1.9 |
variabelnamn | variabelnamn | 2.3d, Hash Table (set) | hash table (set) and DAT simulation | 411 | 3.0 |
whatdoesthefoxsay | whatdoesthefoxsay | 2.3d, Hash Table (set) | use unordered_set to record excluded sounds | 2578 | 2.1 |
babelfish | babelfish | 2.3e, Hash Table (map), E | a pure dictionary problem; use unordered_map; also available at UVa 10282 - Babelfish | 2835 | 2.3 |
candystore | candystore | 2.3e, Hash Table (map), E | we can use hash table; but easier solution exists | 447 | 1.5 |
competitivearcadebasketball | competitivearcadebasketbal... | 2.3e, Hash Table (map), E | use unordered_map | 209 | 2.8 |
conformity | conformity | 2.3e, Hash Table (map), E | use unordered_map to count frequencies of the sorted permutations of 5 ids; also available at UVa 11286 - Conformity | 1100 | 1.9 |
costumecontest | costumecontest | 2.3e, Hash Table (map), E | use unordered_map to map frequency of each category; get the minimum one; print output lexicographically | 532 | 2.0 |
election2 | election2 | 2.3e, Hash Table (map), E | frequency counting; be careful of tie breaker | 166 | 2.4 |
gandalfsspell | gandalfsspell | 2.3e, Hash Table (map), E | map string to char and char to string | 86 | 2.5 |
grandpabernie | grandpabernie | 2.3e, Hash Table (map), E | use unordered_map plus (sorted) vector | 1065 | 3.2 |
haypoints | haypoints | 2.3e, Hash Table (map), E | use unordered_map to deal with Hay Points dictionary; also available at UVa 10295 - Hay Points | 1055 | 2.0 |
marko | marko | 2.3e, Hash Table (map), E | frequency counting with unordered_map | 495 | 1.9 |
metaprogramming | metaprogramming | 2.3e, Hash Table (map), E | use unordered_map; somewhat similar with Kattis - addingwords | 820 | 2.4 |
nicknames | nicknames | 2.3e, Hash Table (map), E | use unordered_map of frequency of prefixes | 364 | 3.3 |
pakethanterare | pakethanterare | 2.3e, Hash Table (map), E | map package name to version number | 454 | 2.0 |
pencilcrayons | pencilcrayons | 2.3e, Hash Table (map), E | for each box, count number of element > 1 (offset -1) | 384 | 1.5 |
planets2 | planets2 | 2.3e, Hash Table (map), E | map species name to planet name; frequency counting | 106 | 3.5 |
recount | recount | 2.3e, Hash Table (map), E | use map; frequency counting | 1163 | 2.0 |
rollcall | rollcall | 2.3e, Hash Table (map), E | use unordered_map to count frequency; sort | 530 | 2.4 |
streetsahead | streetsahead | 2.3e, Hash Table (map), E | map street name to linear indices; find the absolute differences of the indices per query | 438 | 2.1 |
toktik | toktik | 2.3e, Hash Table (map), E | standard frequency counter problem with hash table | 451 | 1.5 |
variablearithmetic | variablearithmetic | 2.3e, Hash Table (map), E | use unordered_map as mapper | 394 | 2.6 |
addingwords | addingwords | 2.3f, Hash Table (map), H | use unordered_map | 1880 | 3.9 |
awkwardparty | awkwardparty | 2.3f, Hash Table (map), H | use unordered_map to running max and running min; report the largest difference | 611 | 3.0 |
basicinterpreter | basicinterpreter | 2.3f, Hash Table (map), H | the harder version of Kattis - variablearithmetic; tedious; be careful; print string inside double quotes verbatim | 152 | 6.7 |
bokforing | bokforing | 2.3f, Hash Table (map), H | use unordered_map to map index to value; for each 'RESTART', clear the hash table in 'faster than O(N)' (amortized) and ... | 493 | 3.8 |
conversationlog | conversationlog | 2.3f, Hash Table (map), H | use combo DS: unordered_map, set, plus (sorted) vector | 507 | 2.8 |
iforaneye | iforaneye | 2.3f, Hash Table (map), H | use unordered_map to map the various rules mentioned in the problem description; tedious | 143 | 5.0 |
kaploeb | kaploeb | 2.3f, Hash Table (map), H | hash the total time and lap count of each start number; sort at the end | 899 | 2.3 |
magicalcows | magicalcows | 2.3f, Hash Table (map), H | use unordered_map of farm size to frequency; small simulation; but since C is small, we can also use DAT | 257 | 4.6 |
minorsetback | minorsetback | 2.3f, Hash Table (map), H | use unordered_map of string to another unordered_map of int to string; need a bit of music theory to solve the problem; ... | 147 | 3.6 |
parallelanalysis | parallelanalysis | 2.3f, Hash Table (map), H | reading comprehension; use unordered_map to map memory address to last time it is written | 80 | 4.8 |
recenice | recenice | 2.3f, Hash Table (map), H | use unordered_map to prepare pronunciation of [1..999]; precalculate the answer afterwards using another unordered_map | 225 | 3.1 |
snowflakes | snowflakes | 2.3f, Hash Table (map), H | use unordered_map to record the occurrence index of a certain snowflake size; use this to determine the answer in linear... | 404 | 4.4 |
bst | bst | 2.3g, Balanced BST (set) | simulate special BST [1..N] insertions using set | 449 | 7.3 |
caching | caching | 2.3g, Balanced BST (set) | combo ds (unordered_map and set) | 210 | 5.8 |
candydivision | candydivision | 2.3g, Balanced BST (set) | complete search from 1 to sqrt(N); insert all divisors into set for automatic sorting and elimination of duplicates | 702 | 3.4 |
compoundwords | compoundwords | 2.3g, Balanced BST (set) | use set extensively; iterator | 1807 | 1.7 |
coursescheduling | coursescheduling | 2.3g, Balanced BST (set) | keep (ordered) set of courses and (unordered) map of course to students taking the course | 40 | 3.1 |
ministryofmagic | ministryofmagic | 2.3g, Balanced BST (set) | simulate directly, use of queue and set (PQ with update key/increase key; use STL set) | 63 | 6.0 |
missinggnomes | missinggnomes | 2.3g, Balanced BST (set) | use set to keep ordered list of missing gnomes | 659 | 2.6 |
orphanbackups | orphanbackups | 2.3g, Balanced BST (set) | use set for auto sorting | 94 | 6.2 |
palindromicpassword | palindromicpassword | 2.3g, Balanced BST (set) | there are not more than 900 3-digits number; generate all and store them in a (sorted) set; find ceil and floor of input... | 431 | 3.3 |
raceday | raceday | 2.3g, Balanced BST (set) | use combo of map; multiset (the most important part for the rankings); and unordered_map | 184 | 3.8 |
raidteams | raidteams | 2.3g, Balanced BST (set) | use more than one PQs that can support erase operation | 75 | 3.5 |
administrativeproblems | administrativeproblems | 2.3h, Balanced BST (map) | use several maps as the output (of spy names) has to be sorted; be careful of corner cases | 194 | 6.3 |
baconeggsandspam | baconeggsandspam | 2.3h, Balanced BST (map) | use map; sort | 1712 | 1.6 |
cakeymccakeface | cakeymccakeface | 2.3h, Balanced BST (map) | map differences to frequencies; return the one with maximum frequency and if ties, the smallest difference | 197 | 3.8 |
doctorkattis | doctorkattis | 2.3h, Balanced BST (map) | Max Priority Queue with frequent (increaseKey) updates; use map | 114 | 4.7 |
fantasydraft | fantasydraft | 2.3h, Balanced BST (map) | use map to keep ordering; simulate; need to erase | 111 | 4.0 |
fodelsedagsmemorisering | fodelsedagsmemorisering | 2.3h, Balanced BST (map) | use map; sorted output | 289 | 1.8 |
hardwoodspecies | hardwoodspecies | 2.3h, Balanced BST (map) | use map; sorted output; also available at UVa 10226 - Hardwood Species | 378 | 2.7 |
kattissquest | kattissquest | 2.3h, Balanced BST (map) | use map of priority queues; other solutions exist | 834 | 3.1 |
maeting | maeting | 2.3h, Balanced BST (map) | map name to frequencies; sort in non-increasing order | 433 | 1.6 |
notamused | notamused | 2.3h, Balanced BST (map) | use map; sorted output | 601 | 2.0 |
opensource | opensource | 2.3h, Balanced BST (map) | use map and set to check previous strings; order needed; also available at UVa 11239 - Open Source | 291 | 3.3 |
problemclassification | problemclassification | 2.3h, Balanced BST (map) | mapper; frequency counting | 345 | 3.1 |
srednji | srednji | 2.3h, Balanced BST (map) | go left and right of B; use fast data structure like map to help determine the result fast | 164 | 4.1 |
warehouse | warehouse | 2.3h, Balanced BST (map) | use unordered_map and multimap | 920 | 2.1 |
zoo | zoo | 2.3h, Balanced BST (map) | parsing; keep last token; tolower; frequency counting with map; order needed | 1499 | 1.7 |
babynames | babynames | 2.3i, Order Statistics Tree | dynamic rank problem; use two pb_ds | 87 | 5.5 |
continuousmedian | continuousmedian | 2.3i, Order Statistics Tree | dynamic selection problem; specifically the median values; pb_ds helps | 140 | 3.9 |
cookieselection | cookieselection | 2.3i, Order Statistics Tree | map large integers to up to 600K integers; use pb_ds or Fenwick Tree and the select(median) operation of Fenwick Tree | 923 | 4.3 |
gcpc | gcpc | 2.3i, Order Statistics Tree | dynamic rank problem; pb_ds helps | 876 | 5.3 |
abinitio | abinitio | 2.4a, Graph Data Structures | combo: EL input, AM as working graph DS, AL output (in hash format); all operations must be O(V) or better | 104 | 7.3 |
alphabetanimals | alphabetanimals | 2.4a, Graph Data Structures | somewhat an Adjacency List data structure | 478 | 3.4 |
chopwood | chopwood | 2.4a, Graph Data Structures | Prüfer sequence; use priority_queue | 258 | 3.5 |
cutthenegativity | cutthenegativity | 2.4a, Graph Data Structures | AM to EL conversion | 1213 | 1.4 |
flyingsafely | flyingsafely | 2.4a, Graph Data Structures | trivial solution exists | 1421 | 1.7 |
hermits | hermits | 2.4a, Graph Data Structures | a simple Graph Data Structure application question | 98 | 3.2 |
illuminatispotti | illuminatispotti | 2.4a, Graph Data Structures | store the graph in an Adjacency Matrix; O(N^3) try-all possible triangles | 30 | 4.3 |
popularitycontest | popularitycontest | 2.4a, Graph Data Structures | a simple graph DS problem | 107 | 2.0 |
railroad | railroad | 2.4a, Graph Data Structures | do as asked; graph DS modification; bypass vertices with degree 2 | 95 | 6.3 |
traveltheskies | traveltheskies | 2.4a, Graph Data Structures | (graph) DS manipulation; an array of ALs (one per each day); simulate the number of people day by day | 188 | 3.2 |
tripplanning | tripplanning | 2.4a, Graph Data Structures | use unordered_map to map bidirectional edges into 1-based indices; simulate the linear journey | 232 | 2.4 |
weakvertices | weakvertices | 2.4a, Graph Data Structures | graph edge existence checks | 1775 | 1.5 |
8queens | 8queens | 3.2b, Iterative (Two Loops) | classic 8-Queens problem; write a checker | 2385 | 3.2 |
antiarithmetic | antiarithmetic | 3.2b, Iterative (Two Loops) | 2 nested loops with pruning can still pass the time limit; compare this with UVa 11129; also available at UVa 10730 - An... | 195 | 7.3 |
bestrelayteam | bestrelayteam | 3.2b, Iterative (Two Loops) | sort runners based on flying start times; brute force first runner and pick top 3 other flying start runners | 1420 | 1.9 |
bikegears | bikegears | 3.2b, Iterative (Two Loops) | 2D nested loops; sort the output | 185 | 5.4 |
blackfriday | blackfriday | 3.2b, Iterative (Two Loops) | 2D nested loops; frequency counting | 2384 | 2.2 |
closestsums | closestsums | 3.2b, Iterative (Two Loops) | sort and then do O(n^2) pairings; also available at UVa 10487 - Closest Sums | 1105 | 2.9 |
codeguessing | codeguessing | 3.2b, Iterative (Two Loops) | try all possible two digits for Bob | 154 | 2.1 |
countdoubles | countdoubles | 3.2b, Iterative (Two Loops) | try all contiguous subarrays of m elements | 311 | 2.0 |
erosionfilter | erosionfilter | 3.2b, Iterative (Two Loops) | for each Ai, just try a few indices around it | 93 | 4.6 |
golombrulers | golombrulers | 3.2b, Iterative (Two Loops) | 2D nested loops; additional 1D loops for checking | 297 | 3.2 |
kafkaesque | kafkaesque | 3.2b, Iterative (Two Loops) | 2D nested loops; simple | 293 | 1.7 |
largesthoarding | largesthoarding | 3.2b, Iterative (Two Loops) | 2D nested loops; try all possible heights and try all N skycrapers | 149 | 3.7 |
liga | liga | 3.2b, Iterative (Two Loops) | 2D nested loops; interesting logic game; each team is independent; if number played and number loss both not defined, as... | 71 | 6.1 |
majstor | majstor | 3.2b, Iterative (Two Loops) | for the second output line; just try each of 'S', 'P', or 'R' at every round and take the max | 101 | 1.9 |
mathtrade | mathtrade | 3.2b, Iterative (Two Loops) | just try all starting point and simulate | 241 | 3.3 |
missingnumber | missingnumber | 3.2b, Iterative (Two Loops) | rolling prefix tests; doable with just 2D nested loops | 387 | 3.3 |
peg | peg | 3.2b, Iterative (Two Loops) | 2D nested loops; try all possible moves | 931 | 1.8 |
pet | pet | 3.2b, Iterative (Two Loops) | very simple 2D nested loops problem | 7932 | 1.4 |
putovanje | putovanje | 3.2b, Iterative (Two Loops) | clever problem with hint that masks possible brute force solution; just use 2D nested loops | 413 | 2.5 |
reduction | reduction | 3.2b, Iterative (Two Loops) | 2 nested loops; with sorting; also available at UVa 10670 - Work Reduction | 119 | 5.8 |
register | register | 3.2b, Iterative (Two Loops) | clever problem with hint that masks possible brute force solution; just use 2D nested loops | 583 | 2.1 |
smoothiestand | smoothiestand | 3.2b, Iterative (Two Loops) | simple 2D nested loops | 195 | 3.0 |
straights | straights | 3.2b, Iterative (Two Loops) | 2 nested loops with pruning | 227 | 3.3 |
summertrip | summertrip | 3.2b, Iterative (Two Loops) | 3 loops TLE; clever 2D nested loops; try all possible ending index i; use DAT to remember the latest lowest starting ind... | 632 | 2.4 |
telephones | telephones | 3.2b, Iterative (Two Loops) | brute force; check intervals; also available at UVa 12205 - Happy Telephones | 302 | 2.6 |
tourdefrance | tourdefrance | 3.2b, Iterative (Two Loops) | brute force plus sorting; also available at UVa 11242 - Tour de France | 354 | 2.7 |
whogoesthere | whogoesthere | 3.2b, Iterative (Two Loops) | small n and m; just simulate the process with 2D nested loop | 157 | 4.1 |
busskortet | busskortet | 3.2c, Three+ Nested Loops, E | try all possible 500, 200, and 100 to ensure correctness | 704 | 3.0 |
cinemaseating | cinemaseating | 3.2c, Three+ Nested Loops, E | 3 nested loops; O(8*R*C); with a small DAT for frequency counter | 68 | 2.5 |
cudoviste | cudoviste | 3.2c, Three+ Nested Loops, E | 4 nested loops; the inner loops is just 2x2; 5 possibilities of crushed cars; skip 2x2 area that contains building | 1194 | 1.4 |
fourdierolls | fourdierolls | 3.2c, Three+ Nested Loops, E | 4 nested loops | 243 | 2.6 |
mathhomework | mathhomework | 3.2c, Three+ Nested Loops, E | 3 nested loops | 257 | 2.1 |
namnsdag | namnsdag | 3.2c, Three+ Nested Loops, E | 3 nested loops | 60 | 2.0 |
npuzzle | npuzzle | 3.2c, Three+ Nested Loops, E | 4 nested loops; easy | 683 | 2.2 |
patuljci | patuljci | 3.2c, Three+ Nested Loops, E | 3 nested loops; n = 9 | 1123 | 1.8 |
radir | radir | 3.2c, Three+ Nested Loops, E | 3 nested loops; never drop any card | 70 | 3.1 |
restaurantopening | restaurantopening | 3.2c, Three+ Nested Loops, E | 4 nested loops | 307 | 1.9 |
safehouses | safehouses | 3.2c, Three+ Nested Loops, E | 4 nested loops | 261 | 3.1 |
set | set | 3.2c, Three+ Nested Loops, E | 4 nested loops; easy | 364 | 1.8 |
triangledrama | triangledrama | 3.2c, Three+ Nested Loops, E | try all O(N^3) triplets | 46 | 2.5 |
firefly | firefly | 3.3a, Binary Search | sort stalactites vs stalagmites separately; brute force height; binary search the obstacles hit | 323 | 4.0 |
massivecardgame | massivecardgame | 3.3a, Binary Search | sort once upfront; upperbound-lowerbound per query | 803 | 3.0 |
outofsorts | outofsorts | 3.3a, Binary Search | do O(log n) binary searches on unsorted array n times | 107 | 3.7 |
roompainting | roompainting | 3.3a, Binary Search | sort the cans at shop (can be used more than once); use lower_bound for what Joe needs at shop | 416 | 3.8 |
synchronizinglists | synchronizinglists | 3.3a, Binary Search | sort and lower_bound | 2130 | 1.5 |
bootstrappingnumber | bootstrappingnumber | 3.3b, Bisection and BSTA, E | BSTA+exponent | 144 | 2.4 |
carefulascent | carefulascent | 3.3b, Bisection and BSTA, E | BSTA + Physics simulation | 558 | 1.8 |
financialplanning | financialplanning | 3.3b, Bisection and BSTA, E | BSTA + observation | 108 | 3.5 |
freeweights | freeweights | 3.3b, Bisection and BSTA, E | BSTA + simulation; Mathematical observation | 356 | 4.5 |
hindex | hindex | 3.3b, Bisection and BSTA, E | BSTA + another binary search | 460 | 3.3 |
htoo | htoo | 3.3b, Bisection and BSTA, E | BSTA + simulation; use DAT | 200 | 2.4 |
monk | monk | 3.3b, Bisection and BSTA, E | BSTA + simulation; cool | 86 | 3.3 |
slalom2 | slalom2 | 3.3b, Bisection and BSTA, E | BSTA + Physics simulation; also available at UVa 11627 - Slalom | 43 | 5.4 |
smallschedule | smallschedule | 3.3b, Bisection and BSTA, E | BSTA + greedy or math | 302 | 3.1 |
speed | speed | 3.3b, Bisection and BSTA, E | LA 8043 - WorldFinals RapidCity17; BSTA + Physics; also available at UVa 01753 - Need for Speed | 955 | 3.2 |
suspensionbridges | suspensionbridges | 3.3b, Bisection and BSTA, E | BSTA + Maths; be careful of precision error | 409 | 4.6 |
svada | svada | 3.3b, Bisection and BSTA, E | BSTA + simulation; process the two types of monkeys separately | 144 | 3.5 |
taxing | taxing | 3.3b, Bisection and BSTA, E | BSTA + simulation; use double; be careful of precision errors | 143 | 4.7 |
acm2 | acm2 | 3.4b, Involving Sorting, E | greedy; sorting | 790 | 2.6 |
akcija | akcija | 3.4b, Involving Sorting, E | greedy; sorting | 2658 | 2.0 |
aprizenoonecanwin | aprizenoonecanwin | 3.4b, Involving Sorting, E | greedy; sorting | 790 | 2.5 |
cocktail | cocktail | 3.4b, Involving Sorting, E | sort; greedy | 1191 | 2.9 |
fallingapart | fallingapart | 3.4b, Involving Sorting, E | greedy; sorting | 1011 | 1.6 |
fridge | fridge | 3.4b, Involving Sorting, E | greedy; sorting | 429 | 3.1 |
gettowork | gettowork | 3.4b, Involving Sorting, E | greedy; sorting | 255 | 2.2 |
help | help | 3.4b, Involving Sorting, E | greedy; sorting | 60 | 7.5 |
hotsprings | hotsprings | 3.4b, Involving Sorting, E | greedy; sorting | 86 | 1.9 |
icpcteamselection | icpcteamselection | 3.4b, Involving Sorting, E | greedy; sorting | 586 | 3.0 |
linesperhour | linesperhour | 3.4b, Involving Sorting, E | sort; greedy | 595 | 1.7 |
minimumscalar | minimumscalar | 3.4b, Involving Sorting, E | greedy; sorting | 1202 | 2.3 |
pikemaneasy | pikemaneasy | 3.4b, Involving Sorting, E | greedy; sorting | 473 | 3.5 |
pizzubestun | pizzubestun | 3.4b, Involving Sorting, E | sort; greedy every two indices; a bit different between odd and even n | 323 | 2.2 |
planetaris | planetaris | 3.4b, Involving Sorting, E | greedy; sorting | 143 | 2.8 |
plantingtrees | plantingtrees | 3.4b, Involving Sorting, E | greedy; sorting | 3462 | 2.0 |
redistribution | redistribution | 3.4b, Involving Sorting, E | greedy; sorting | 537 | 2.0 |
sangbok | sangbok | 3.4b, Involving Sorting, E | sort; greedy | 200 | 1.9 |
shopaholic | shopaholic | 3.4b, Involving Sorting, E | greedy; sorting | 959 | 2.4 |
stadiljus | stadiljus | 3.4b, Involving Sorting, E | sort; greedy | 315 | 2.2 |
standings | standings | 3.4b, Involving Sorting, E | greedy; sorting | 329 | 4.1 |
textmessaging | textmessaging | 3.4b, Involving Sorting, E | greedy; sorting | 222 | 2.9 |
toflur | toflur | 3.4b, Involving Sorting, E | greedy; sorting | 178 | 2.5 |
universityzoning | universityzoning | 3.4b, Involving Sorting, E | greedy; sorting; use Manhattan distance to compute distances | 122 | 2.5 |
woodcutting | woodcutting | 3.4b, Involving Sorting, E | greedy; sorting | 572 | 3.1 |
annoyedcoworkers | annoyedcoworkers | 3.4d, Involving PQ | greedy PQ simulation | 429 | 3.2 |
arraysmoothening | arraysmoothening | 3.4d, Involving PQ | greedy PQ simulation | 1291 | 2.6 |
ballotboxes | ballotboxes | 3.4d, Involving PQ | greedy; priority queue | 776 | 4.4 |
canvas | canvas | 3.4d, Involving PQ | greedy; priority queue | 214 | 3.5 |
entertainmentbox | entertainmentbox | 3.4d, Involving PQ | sort; greedy simulation; Priority Queue with update key (we can use multiset) | 274 | 6.0 |
vegetables | vegetables | 3.4d, Involving PQ | greedy; priority queue | 347 | 3.4 |
workstations | workstations | 3.4d, Involving PQ | greedy; priority queue | 1110 | 3.6 |
cartrouble | cartrouble | 4.2a, Finding CCs | graph traversal on forward and reverse graphs | 106 | 4.4 |
daceydice | daceydice | 4.2a, Finding CCs | reachability test of a state-space graph; s: (r, c, where_is_five) | 171 | 3.5 |
dominoes2 | dominoes2 | 4.2a, Finding CCs | unlike UVa 11504, we treat SCCs as CCs; also available at UVa 11518 - Dominos 2 | 599 | 3.3 |
moneymatters | moneymatters | 4.2a, Finding CCs | see if the sum of vertex weights of each CC = 0 | 990 | 3.1 |
pearwise | pearwise | 4.2a, Finding CCs | clever problem wording; can be reduced into basic graph traversal | 159 | 3.7 |
reachableroads | reachableroads | 4.2a, Finding CCs | report number of CC-1 | 892 | 2.1 |
sailingfriends | sailingfriends | 4.2a, Finding CCs | find number of CCs without any boat in a medium-sized undirected graph | 293 | 2.5 |
securitybadge | securitybadge | 4.2a, Finding CCs | reachability test; clever idea to compress ids | 87 | 6.6 |
skyislands | skyislands | 4.2a, Finding CCs | reachability test | 37 | 2.1 |
terraces | terraces | 4.2a, Finding CCs | group cells with similar height together; if it cannot flow to any other component with lower height, add the size of th... | 339 | 3.6 |
wheresmyinternet | wheresmyinternet | 4.2a, Finding CCs | check connectivity to vertex 1 | 1716 | 3.7 |
amoebas | amoebas | 4.2b, Flood Fill, Easier | easy floodfill | 1079 | 1.8 |
countingstars | countingstars | 4.2b, Flood Fill, Easier | basic flood fill problem; count CCs | 1494 | 2.7 |
floodit | floodit | 4.2b, Flood Fill, Easier | multiple calls of flood fill tests | 74 | 2.9 |
fontan | fontan | 4.2b, Flood Fill, Easier | modified multi-sources BFS/floodfill | 101 | 2.2 |
gold | gold | 4.2b, Flood Fill, Easier | flood fill with extra blocking constraint; also available at UVa 11561 - Getting Gold | 735 | 2.2 |
wheresmywaterfall | wheresmywaterfall | 4.2b, Flood Fill, Easier | identical with Kattis - fontan | 230 | 3.0 |
brexit | brexit | 4.2d, Topological Sort | toposort; chain reaction; modified Kahn's algorithm | 826 | 3.6 |
brexitnegotiations | brexitnegotiations | 4.2d, Topological Sort | toposort with modified Kahn's algorithm; greedy | 270 | 4.8 |
builddeps | builddeps | 4.2d, Topological Sort | the graph is acyclic; toposort with DFS from the changed file | 626 | 4.7 |
collapse | collapse | 4.2d, Topological Sort | similar with Kattis - brexit | 77 | 5.8 |
conservation | conservation | 4.2d, Topological Sort | modified Kahn's algorithm; greedily process all steps in a certain lab before alternating to the other lab | 133 | 4.2 |
curveknights | curveknights | 4.2d, Topological Sort | input is a DAG; multi-sources, find toposort; propagate using topological order | 46 | 3.3 |
digicomp2 | digicomp2 | 4.2d, Topological Sort | toposort helps avoid TLE; do not simulate the process n times as n can be as big as 10^18 | 288 | 5.9 |
grapevine | grapevine | 4.2d, Topological Sort | BFS variant; like Kahn's algorithm, only propagate from a person once his/her skepticism level is cleared; be careful wi... | 84 | 6.4 |
managingpackaging | managingpackaging | 4.2d, Topological Sort | if the graph is cyclic, output 'cannot be ordered'; otherwise, find the lexicographically smallest topological order | 128 | 5.9 |
pickupsticks | pickupsticks | 4.2d, Topological Sort | cycle check + toposort if DAG; also available at item UVa 11686 - Pick up sticks | 373 | 4.7 |
amanda | amanda | 4.2e, Graph Properties Check | add edge only among airports where only one end point has lounge; bicolouring/bipartite check; pick colour with smaller ... | 368 | 5.2 |
ballsandneedles | ballsandneedles | 4.2e, Graph Properties Check | cycle check on 2 similar graphs; easier solution exists | 161 | 3.2 |
breakingbad | breakingbad | 4.2e, Graph Properties Check | check if we can decompose the vertices into two disjoint sets; bipartite graph check | 643 | 4.2 |
hoppers | hoppers | 4.2e, Graph Properties Check | the answer is number of CC-1 if there is at least one non-bipartite component in the graph; or number of CC otherwise | 234 | 3.9 |
molekule | molekule | 4.2e, Graph Properties Check | undirected tree is also Bipartite/bi-colorable; bi-color it with 0 and 1; direct all edges from 0 to 1 (or vice versa) | 175 | 3.5 |
pubs | pubs | 4.2e, Graph Properties Check | isolated vertex has no solution; this is actually not a bipartite graph check; we can do alternate labeling of vertices ... | 216 | 3.5 |
runningmom | runningmom | 4.2e, Graph Properties Check | find a cycle in a directed graph | 591 | 3.8 |
torn2pieces | torn2pieces | 4.2e, Graph Properties Check | construct graph from strings; traversal from source to target; reachability check; print path | 1115 | 3.6 |
ads | ads | 4.2h, Really Ad Hoc | modified traversal; can we reach an illegal character from a frame - remove that ads once | 218 | 5.1 |
brickwall | brickwall | 4.2h, Really Ad Hoc | s: (n1, n2, n3); number of type 1/2/3 bricks used so far; max is (c1, c2, c3); prefix sum to check if a position has a b... | 91 | 5.1 |
connectn | connectn | 4.2h, Really Ad Hoc | ad hoc straight-line (implicit) graph traversal | 397 | 3.1 |
droppingdirections | droppingdirections | 4.2h, Really Ad Hoc | modified graph: a vertex is (origin intersection id, intersection id); modified DFS from vertices leading to goal; count... | 87 | 3.5 |
faultyrobot | faultyrobot | 4.2h, Really Ad Hoc | interesting graph traversal variant | 182 | 4.5 |
promotions | promotions | 4.2h, Really Ad Hoc | modified DFS; special graph; DAG; also available at UVa 13015 - Promotions | 129 | 5.5 |
silueta | silueta | 4.2h, Really Ad Hoc | 2D grid processing initially; modified DFS to count perimeter of polygon in grid | 37 | 5.3 |
succession | succession | 4.2h, Really Ad Hoc | (upwards) traversal of family DAG; use unordered_maps; make the founder has very large starting blood to avoid fraction | 165 | 3.1 |
buttonbashing | buttonbashing | 4.4a, SSSP, BFS, Easier | very similar to UVa 12160 | 728 | 3.4 |
elevatortrouble | elevatortrouble | 4.4a, SSSP, BFS, Easier | s: (cur_level); only 1M floors; go up/down; BFS | 362 | 3.1 |
grid | grid | 4.4a, SSSP, BFS, Easier | modified BFS with step size multiplier | 1026 | 2.8 |
horror | horror | 4.4a, SSSP, BFS, Easier | SSSP from all sources = horror movies; report lowest ID with the highest unweighted SSSP distance | 500 | 3.3 |
interplanetarytunnels | interplanetarytunnels | 4.4a, SSSP, BFS, Easier | simple BFS from pa; output dist[pb]/2 (round up) | 273 | 2.2 |
modulosolitaire | modulosolitaire | 4.4a, SSSP, BFS, Easier | s: (cur_sj); try all n (n ≤ 10) possible moves; BFS | 286 | 3.0 |
onaveragetheyrepurple | onaveragetheyrepurple | 4.4a, SSSP, BFS, Easier | reading comprehension; the answer is just unweighted SSSP from 1 to N, minus one; BFS | 518 | 3.1 |
spiral | spiral | 4.4a, SSSP, BFS, Easier | generate the 2D 100x100 spiraling grid first; involving small primes; BFS | 148 | 3.5 |
wettiles | wettiles | 4.4a, SSSP, BFS, Easier | multi-sources BFS; limited flood fill or unweighted SSSP limited to step T | 227 | 3.6 |
grasshopper | grasshopper | 4.4c, Knight Moves | BFS on implicit Knight jump graph | 136 | 4.0 |
hidingplaces | hidingplaces | 4.4c, Knight Moves | SSSP from (r, c); find cells with max distance; print | 607 | 1.9 |
knightjump | knightjump | 4.4c, Knight Moves | unweighted SSSP from the cell that contains 'K' to (1, 1) using Knight jump movements; avoid '#' cells | 292 | 2.5 |
flowerytrails | flowerytrails | 4.4d, SSSP, Dijkstra, Easier | Dijkstra's; record predecessor graph as there can be multiple shortest paths; also available at UVa 12878 - Flowery Trai... | 305 | 3.9 |
george | george | 4.4d, SSSP, Dijkstra, Easier | not easy, rating deceptive: Dijkstra's but with a few constraints; some roads are blocked at certain timings; similar wi... | 205 | 2.0 |
getshorty | getshorty | 4.4d, SSSP, Dijkstra, Easier | log(f) when f in [0..1] is negative; log(f1 * f2 * ... * fn) = log(f1) + log(f2) + ... + log(fn); longest path; use max... | 1572 | 3.4 |
hopscotch50 | hopscotch50 | 4.4d, SSSP, Dijkstra, Easier | MSSP from all 1s; implicit weighted graph; stop at first cell with value k | 200 | 2.3 |
shortestpath1 | shortestpath1 | 4.4d, SSSP, Dijkstra, Easier | very standard Dijkstra's problem | 1470 | 3.5 |
shortestpath2 | shortestpath2 | 4.4d, SSSP, Dijkstra, Easier | Dijkstra's with modification; edges only available periodically; be careful with P = 0 case | 423 | 3.9 |
subway2 | subway2 | 4.4d, SSSP, Dijkstra, Easier | use basic geometry skill to build the weighted graph; then run Dijkstra's; also available at UVa 10389 - Subway | 70 | 5.9 |
texassummers | texassummers | 4.4d, SSSP, Dijkstra, Easier | Dijkstra's; complete weighted graph; print path | 97 | 4.0 |
crosscountry | crosscountry | 4.4f, SSSP, -ve weight | medium complete graph with N ≤ 1000; Bellman-Ford can still pass (or use Dijkstra's) | 217 | 3.0 |
hauntedgraveyard | hauntedgraveyard | 4.4f, SSSP, -ve weight | Bellman-Ford; negative cycle check needed | 95 | 8.2 |
shortestpath3 | shortestpath3 | 4.4f, SSSP, -ve weight | Bellman-Ford; do DFS/BFS from vertices that are part of any negative cycle | 524 | 5.1 |
xyzzy | xyzzy | 4.4f, SSSP, -ve weight | check 'positive' cycle; check connectedness; also available at UVa 10557 | 152 | 6.7 |
ecoins | ecoins | 8.2b, State-Space, BFS, E | s: (conventional-value, infotechnological-value); BFS; also available at UVa 10306 - e-Coins | 169 | 4.6 |
flipfive | flipfive | 8.2b, State-Space, BFS, E | s: (bitmask); only 2^9 = 512 grid configurations; BFS | 621 | 2.7 |
hydrasheads | hydrasheads | 8.2b, State-Space, BFS, E | s: (cur_H, cur_T); BFS; but easier solution exists | 551 | 1.7 |
illiteracy | illiteracy | 8.2b, State-Space, BFS, E | s: (string); 6 different transition rules; BFS | 126 | 2.9 |
safe | safe | 8.2b, State-Space, BFS, E | s: (convert 3x3 grid into a base 4 integer); BFS | 181 | 3.0 |
bigtruck | bigtruck | 8.2d, State-Space, Dijkstra | s: (city, items_picked); use Dijkstra's | 1144 | 3.2 |
bumped | bumped | 8.2d, State-Space, Dijkstra | s: (city, has_use_free_ticket); use Dijkstra's | 545 | 4.4 |
destinationunknown | destinationunknown | 8.2d, State-Space, Dijkstra | use Dijkstra's twice; one normally; one with s: (point, has_edge_g_h_used); compare the results | 101 | 5.6 |
justpassingthrough | justpassingthrough | 8.2d, State-Space, Dijkstra | s: (r, c, n_left); Dijkstra's/SSSP on DAG | 92 | 5.1 |
kitchen | kitchen | 8.2d, State-Space, Dijkstra | s: (volume_of_the_n_cups); t: try all possible pourings; use Dijkstra's | 152 | 3.5 |
quantum | quantum | 8.2d, State-Space, Dijkstra | s: (bitmask); t: all of the nop operations; use Dijkstra's | 82 | 3.3 |
rainbowroadrace | rainbowroadrace | 8.2d, State-Space, Dijkstra | s: (pos, bitmask_of_7_colors); use Dijkstra's | 101 | 2.9 |
treasure | treasure | 8.2d, State-Space, Dijkstra | s: (day, k_left, cur_r, cur_c); use Dijkstra's | 118 | 8.0 |
xentopia | xentopia | 8.2d, State-Space, Dijkstra | s: (u, k1_used, k2_used); use Dijkstra's | 184 | 4.6 |