Codeforces problemset search & solutions
Exclude tags.

Review the problem statement from Codeforces (link will open a new tab). When you've matched your problem, go to the solutions.

Search on plain tags, ratings, names, and problem text. Example: brute force or binary search

< 1 2

Solved
Name
Tags
Solutions
Index
Contest
Type
Points
Tutorial
Rating Level
2896 Multi-Colored Segments binary search data structures math sortings Statement F Codeforces Round 826 (Div. 3) {1741} PROGRAMMING 107908
43801 Traffic Light binary search implementation two pointers Statement C Codeforces Round 828 (Div. 3) {1744} PROGRAMMING Codeforces Round #828 (Div. 3) Editorial
247 Doremy's Paint 2 data structures Statement H Codeforces Global Round 24 {1764} PROGRAMMING 3500.0 Codeforces Global Round 24 Editorial
1249 Algebra Flash bitmasks brute force dp graphs meet-in-the-middle trees Statement E Educational Codeforces Round 140 (Rated for Div. 2) {1767} PROGRAMMING 110225
796 Hossam and a Letter brute force dp implementation two pointers Statement E Codeforces Round 837 (Div. 2) {1771} PROGRAMMING 2750.0 Codeforces Round #837 (Div. 2) Editorial
13972 Coloring constructive algorithms greedy Statement B Polynomial Round 2022 (Div. 1 + Div. 2, Rated, Prizes!) {1774} PROGRAMMING 1000.0 Polynomial Round 2022 (Div. 1 + Div. 2) Editorial
1553 Vittorio Plays with LEGO Bricks dp Statement B SWERC 2022-2023 - Online Mirror (Unrated, ICPC Rules, Teams Preferred) {1776} PROGRAMMING
12208 Alternating Deck (hard version) implementation Statement A2 Codeforces Round 850 (Div. 2, based on VK Cup 2022 - Final Round) {1786} PROGRAMMING 500.0 Codeforces Round #850 Editorial
501 Graph Coloring (hard version) brute force fft Statement F2 Educational Codeforces Round 142 (Rated for Div. 2) {1792} PROGRAMMING 111835
985 Graph Coloring (easy version) dp Statement F1 Educational Codeforces Round 142 (Rated for Div. 2) {1792} PROGRAMMING 111835
24634 Two Towers brute force implementation strings Statement A Educational Codeforces Round 143 (Rated for Div. 2) {1795} PROGRAMMING 112963
13006 Triangle Coloring combinatorics math Statement D Educational Codeforces Round 143 (Rated for Div. 2) {1795} PROGRAMMING 112963
1028 Colored Subgraphs data structures dp greedy trees Statement E Educational Codeforces Round 144 (Rated for Div. 2) {1796} PROGRAMMING Educational Codeforces Round 144 Editorial
9726 The Very Beautiful Blanket bitmasks constructive algorithms Statement A Codeforces Round 857 (Div. 1) {1801} PROGRAMMING 500.0 Codeforces Round #857 Editorial
25142 Garland implementation Statement A Educational Codeforces Round 145 (Rated for Div. 2) {1809} PROGRAMMING 114300
2119 Vlad and the Nice Paths (hard version) binary search combinatorics data structures dp math two pointers Statement G2 Codeforces Round 863 (Div. 3) {1811} PROGRAMMING 114788
2481 Vlad and the Nice Paths (easy version) combinatorics dp math Statement G1 Codeforces Round 863 (Div. 3) {1811} PROGRAMMING 114788
929 Mex Tree brute force dp trees Statement D Codeforces Round 875 (Div. 1) {1830} PROGRAMMING 2250.0 Codeforces Round #875 (Div.1 + Div. 2) Editorial
21870 Bracket Coloring constructive algorithms data structures greedy Statement D Educational Codeforces Round 149 (Rated for Div. 2) {1837} PROGRAMMING 116752
2690 Ball Sorting data structures dp sortings Statement D Codeforces Round 876 (Div. 2) {1839} PROGRAMMING 2250.0 Codeforces Round #876 (Div. 2) Editorial
37280 Sasha and Array Coloring greedy sortings Statement A Codeforces Round 881 (Div. 3) {1843} PROGRAMMING Codeforces Round #881 (Div. 3) Editorial
24274 Vika and the Bridge binary search data structures greedy implementation math sortings Statement B Codeforces Round 885 (Div. 2) {1848} PROGRAMMING 1000.0 Codeforces Round #885 (Div.2) Editorial
78371 Array Coloring greedy math Statement A Codeforces Round 891 (Div. 3) {1857} PROGRAMMING 119134
10756 Two-Colored Dominoes constructive algorithms greedy Statement D Pinely Round 2 (Div. 1 + Div. 2) {1863} PROGRAMMING 1250.0
13092 Colorful Table binary search data structures dp implementation math sortings two pointers Statement C CodeTON Round 6 (Div. 1 + Div. 2, Rated, Prizes!) {1870} PROGRAMMING 1500.0 CodeTON Round 6 (Div. 1 + Div. 2, Rated, Prizes!) Editorial
1566 Interactive Game with Coloring brute force constructive algorithms graphs implementation interactive math trees Statement E Educational Codeforces Round 155 (Rated for Div. 2) {1879} PROGRAMMING 120773 2400
493 Good Colorings binary search constructive algorithms graphs interactive Statement E Codeforces Round 905 (Div. 1) {1887} PROGRAMMING 2000.0 Codeforces Round #905 (Div. 1, Div. 2, Div. 3) Editorial
1090 Colorful Constructive constructive algorithms greedy math Statement D Codeforces Round 908 (Div. 1) {1893} PROGRAMMING 2250.0 Codeforces Round 908 (Div. 1, Div, 2) Editorial
321 Two Characters, Two Colors binary search data structures dp flows geometry Statement G Educational Codeforces Round 157 (Rated for Div. 2) {1895} PROGRAMMING Educational Codeforces Round 157 Editorial
55 Two Colors *special Statement J Kotlin Heroes: Episode 9 (Unrated, T-Shirts + Prizes!) {1910} PROGRAMMING 123261
14220 Game with Marbles (Easy Version) brute force games greedy sortings Statement E1 Codeforces Round 916 (Div. 3) {1914} PROGRAMMING Codeforces Round 916 (Div. 3) Editorial
14723 Game with Marbles (Hard Version) games greedy sortings Statement E2 Codeforces Round 916 (Div. 3) {1914} PROGRAMMING Codeforces Round 916 (Div. 3) Editorial
2593 Tree Compass constructive algorithms dfs and similar greedy trees Statement C Codeforces Round 934 (Div. 1) {1943} PROGRAMMING 1250.0 Codeforces Round #934 (Div1, Div2) Editorial
8020 Colored Balls combinatorics dp greedy math sortings Statement D Educational Codeforces Round 164 (Rated for Div. 2) {1954} PROGRAMMING Educational Codeforces Round 164 Editorial
27485 Painting the Ribbon math Statement A Educational Codeforces Round 164 (Rated for Div. 2) {1954} PROGRAMMING Educational Codeforces Round 164 Editorial
463 Connected Cubes constructive algorithms games Statement E Codeforces Round 941 (Div. 1) {1965} PROGRAMMING 2500.0 Codeforces Round #941 (Div. 1, Div. 2) Editorial 3100
17189 Rectangle Filling constructive algorithms implementation Statement B Codeforces Round 941 (Div. 2) {1966} PROGRAMMING 1000.0 Codeforces Round #941 (Div. 1, Div. 2) Editorial 1100
2730 ±1 2-sat dfs and similar graphs Statement H Codeforces Round 944 (Div. 4) {1971} PROGRAMMING Codeforces Round 944 (Div. 4) Editorial 2100
604 Simultaneous Coloring dfs and similar divide and conquer graphs Statement F Educational Codeforces Round 167 (Rated for Div. 2) {1989} PROGRAMMING Educational Codeforces Round 167 Editorial
7877 Prime XOR Coloring bitmasks constructive algorithms graphs greedy math number theory Statement D Pinely Round 4 (Div. 1 + Div. 2) {1991} PROGRAMMING 1500.0 Video Tutorial
5106 Coloring Game constructive algorithms games graphs greedy interactive Statement E Pinely Round 4 (Div. 1 + Div. 2) {1991} PROGRAMMING 2000.0 Video Tutorial
21308 Distanced Coloring constructive algorithms implementation math Statement A EPIC Institute of Technology Round August 2024 (Div. 1 + Div. 2) {2002} PROGRAMMING 500.0 EPIC Institute of Technology Round August 2024 (Div. 1 + Div. 2) Editorial
13221 Colored Portals binary search data structures graphs greedy shortest paths Statement D Educational Codeforces Round 169 (Rated for Div. 2) {2004} PROGRAMMING Educational Codeforces Round 169 Editorial
164 Dora's Paint brute force combinatorics constructive algorithms graphs Statement F Codeforces Round 969 (Div. 1) {2006} PROGRAMMING 3000.0 Tutorial
77 Simurgh's Watch (Easy Version) greedy implementation Statement G1 Rayan Programming Contest 2024 - Selection (Codeforces Round 989, Div. 1 + Div. 2) {2034} PROGRAMMING 3000.0 Rayan 2024 Selection Round Editorial
77 Simurgh's Watch (Hard Version) greedy implementation Statement G2 Rayan Programming Contest 2024 - Selection (Codeforces Round 989, Div. 1 + Div. 2) {2034} PROGRAMMING 3000.0 Rayan 2024 Selection Round Editorial
1664 Library of Magic binary search bitmasks constructive algorithms interactive Statement G Codeforces Round 984 (Div. 3) {2036} PROGRAMMING Codeforces Round 984 (Div. 3) Editorial
451 Number of Cubes combinatorics math number theory Statement F Codeforces Round 992 (Div. 2) {2040} PROGRAMMING 2750.0 Codeforces Round #992 (Div.2) Editorial
67 Grid Game Statement G 2024 ICPC Asia Taichung Regional Contest (Unrated, Online Mirror, ICPC Rules, Preferably Teams) {2041} PROGRAMMING Problem Analysis and Hints (PDF)
7154 Bowling Frame binary search math Statement B 2024 ICPC Asia Taichung Regional Contest (Unrated, Online Mirror, ICPC Rules, Preferably Teams) {2041} PROGRAMMING Problem Analysis and Hints (PDF)
19461 Game with Colored Marbles games greedy Statement B Educational Codeforces Round 172 (Rated for Div. 2) {2042} PROGRAMMING 136886
18737 Set of Strangers greedy matrices Statement B Educational Codeforces Round 174 (Rated for Div. 2) {2069} PROGRAMMING 139774
14282 Two Colors binary search data structures dp math Statement C Educational Codeforces Round 176 (Rated for Div. 2) {2075} PROGRAMMING Educational Codeforces Round 176 Editorial
3801 She knows... combinatorics constructive algorithms graphs math Statement E Codeforces Round 1014 (Div. 2) {2092} PROGRAMMING 2250.0 Codeforces Round #1014 (Div. 2) Editorial
2032 Wonderful Teddy Bears greedy implementation sortings Statement E Neowise Labs Contest 1 (Codeforces Round 1018, Div. 1 + Div. 2) {2096} PROGRAMMING 2000.0 Neowise Labs Contest 1 (Codeforces Round 1018, Div. 1 + Div. 2) Editorial
16506 Wonderful Gloves greedy math sortings Statement B Neowise Labs Contest 1 (Codeforces Round 1018, Div. 1 + Div. 2) {2096} PROGRAMMING 750.0 Neowise Labs Contest 1 (Codeforces Round 1018, Div. 1 + Div. 2) Editorial
525 Modulo 3 data structures divide and conquer dsu trees Statement G Educational Codeforces Round 178 (Rated for Div. 2) {2104} PROGRAMMING Educational Codeforces Round 178 Editorial
878 Spruce Dispute constructive algorithms dfs and similar graphs implementation shortest paths trees Statement E Codeforces Round 1022 (Div. 2) {2108} PROGRAMMING 2750.0 Codeforces Round 1022 Editorial
17642 Coloring Game binary search brute force greedy two pointers Statement C Educational Codeforces Round 180 (Rated for Div. 2) {2112} PROGRAMMING Educational Codeforces Round 180 — Editorial
4276 1-1-1, Free Tree! data structures dfs and similar graphs trees Statement F Codeforces Round 1037 (Div. 3) {2126} PROGRAMMING 144845
2726 Ancient Tree constructive algorithms data structures dfs and similar dsu greedy trees Statement E Atto Round 1 (Codeforces Round 1041, Div. 1 + Div. 2) {2127} PROGRAMMING 2500.0 Atto Round 1 (Codeforces Round 1041, Div. 1 + Div. 2) Editorial
26486 Painting With Two Colors constructive algorithms implementation math Statement A Codeforces Round 1045 (Div. 2) {2134} PROGRAMMING 500.0 145832
6368 Inversion Graph Coloring (Easy Version) binary search data structures dp two pointers Statement D1 Codeforces Round 1051 (Div. 2) {2143} PROGRAMMING 1750.0 Codeforces Round 1051 (Div. 2) Editorial
2747 Inversion Graph Coloring (Hard Version) binary search data structures dp two pointers Statement D2 Codeforces Round 1051 (Div. 2) {2143} PROGRAMMING 1000.0 Codeforces Round 1051 (Div. 2) Editorial
523 Cost of Coloring combinatorics fft math Statement G Educational Codeforces Round 183 (Rated for Div. 2) {2145} PROGRAMMING Educational Codeforces Round 183 Editorial
185 Maxflow GCD Coloring flows graphs Statement H Codeforces Global Round 29 (Div. 1 + Div. 2) {2147} PROGRAMMING 5500.0
11644 Incremental Path data structures implementation Statement A Codeforces Round 1053 (Div. 1) {2150} PROGRAMMING 500.0 Editorial of Codeforces Round 1053 (Div. 1, Div. 2)
197 Victorious Coloring (Hard Version) data structures data structures data structures data structures Statement H2 Squarepoint Challenge (Codeforces Round 1055, Div. 1 + Div. 2) {2152} PROGRAMMING 2500.0 Squarepoint Challenge (Codeforces Round 1055, Div. 1 + Div. 2) Editorial
589 Victorious Coloring (Easy Version) dp graphs Statement H1 Squarepoint Challenge (Codeforces Round 1055, Div. 1 + Div. 2) {2152} PROGRAMMING 4000.0 Squarepoint Challenge (Codeforces Round 1055, Div. 1 + Div. 2) Editorial
632 Juan's Colorful Tree data structures data structures dfs and similar dfs and similar dsu graphs graphs trees Statement F Codeforces Round 1056 (Div. 2) {2155} PROGRAMMING 3000.0 Codeforces Round 1056 (Div. 2) Editorial
251 Rainbow Branch dp trees Statement E Codeforces Round 1064 (Div. 1) {2165} PROGRAMMING 3000.0 148452
453 Mosaic Tree combinatorics dp fft math trees Statement F Codeforces Round 1069 (Div. 1) {2174} PROGRAMMING 3500.0 Codeforces Round 1069 Editorial
1146 Beautiful Patterns (Easy Version) math probabilities Statement C1 Codeforces Round 1069 (Div. 1) {2174} PROGRAMMING 1500.0 Codeforces Round 1069 Editorial
1005 Beautiful Patterns (Hard Version) math probabilities Statement C2 Codeforces Round 1069 (Div. 1) {2174} PROGRAMMING 500.0 Codeforces Round 1069 Editorial
18635 Little Fairy's Painting implementation Statement A Codeforces Round 1069 (Div. 2) {2175} PROGRAMMING 500.0 Codeforces Round 1069 Editorial
2724 Blackslex and Another RGB Walking graphs interactive number theory Statement F Codeforces Round 1071 (Div. 3) {2179} PROGRAMMING Codeforces Round 1071 (Div. 3) Editorial
64 Knit the Grid Statement K 2025-2026 ICPC, NERC, Northern Eurasia Finals (Unrated, Online Mirror, ICPC Rules, Teams Preferred) {2181} PROGRAMMING Tutorial
27630 Array Coloring constructive algorithms Statement A Codeforces Round 1073 (Div. 2) {2191} PROGRAMMING 500.0 Codeforces Round 1073 (Div. 1, Div. 2) Editorial
263 Hanabi data structures dp flows graph matchings graphs greedy Statement F Codeforces Round 1085 (Div. 1 + Div. 2) {2207} PROGRAMMING 3250.0 Codeforces Round 1085 (Div. 1 + Div. 2) Editorial
5181 Ghostfires constructive algorithms greedy Statement D Codeforces Round 1087 (Div. 2) {2209} PROGRAMMING 1750.0 Codeforces Round 1087 (Div. 2) Editorial