#2-sat
CF 1089H - Harder Satisfiability
CF 1089H - Harder Satisfiability Rating: 3400 Tags: 2-sat, dfs and similar, graphs Solve time: 2m 35s Verified: yes Solution Problem Understanding We are given a logical system built from boolean variables, where constraints are expressed as implications between literals. Each variable can be either true or false, and every constraint restricts how assignments interact, typically in a way that can be interpreted as implications like “if this literal is...
CF 1403A - The Potion of Great Power
CF 1403A - The Potion of Great Power Rating: 2400 Tags: *special, 2-sat, binary search, data structures, graphs, interactive, sortings, two pointers Solve time: 2m 3s Verified: no Solution Problem Understanding We have a dynamic friendship network among N shamans, each living at a specific altitude H[i] . Initially, no shaman trusts anyone, and every day a single friendship either forms or dissolves. Each shaman can trust at most D...
CF 2061C - Kevin and Puzzle
CF 2061C - Kevin and Puzzle Rating: 1600 Tags: 2-sat, combinatorics, dp Solve time: 1m 49s Verified: yes Solution Problem Understanding We have a line of classmates, each of whom claims a certain number of liars standing to their left. Each person is either honest, in which case their claim is exactly true, or a liar, in which case their claim may be arbitrary. Additionally, liars cannot stand next to...
CF 2181K - Knit the Grid
CF 2181K - Knit the Grid Rating: 3500 Tags: 2-sat, constructive algorithms, graphs, matrices Solve time: 2m 47s Verified: no Solution Problem Understanding The canvas is a rectangular grid of cells, but the real structure lives on its grid graph: vertices are grid intersection points and edges connect adjacent intersections horizontally or vertically. Initially, some collection of simple cycles is drawn along these edges. The cycles are vertex-disjoint, and every...