- Algorithm Review - Prefix Sum and Difference Array
Review of 1D/2D prefix sums and difference arrays for range sum queries and range updates.
3 min read en - XOR Array - Codeforces Solution
Construct a positive integer array where exactly the specified subarrays have XOR value zero, using prefix XOR with unique repetition.
4 min read en - The Curse of the Frog - Codeforces Solution
A frog jumps on a number line with max distance and periodic penalty per jump type. Find the minimum penalty count to reach the target.
5 min read en - MEX Reordering - Codeforces Solution
Rearrange an array so that no prefix and suffix share the same MEX value. Key insight: analyze occurrences of zero and one.
5 min read en - XOR Convenience - Codeforces Solution
Construct a permutation where each value XORed with a later value equals the index. Core idea: direct all XOR results to the last position.
4 min read en