Is This a Long Challenge
You are given a string $S$ of length $N$ consisting only of A's and B's. You will be given $Q$ queries each of which can be either of Type 1 or Type 2. - For a query of Type 1, you will be given two numbers $L$ and $R$ and a character $C$. You are supposed to replace every character in $S$ from position $L$ to $R$ with $C$. - For a query of Type 2, you will be given 4 numbers $L$, $R$, $p$ and
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start