Make a String
CodeChefOpen on judge ↗
You have an initially empty string $S$, a target string $T$ and a sequence of $n$ strings $p_1, p_2, \dots, p_n$. You may perform any number of operations; let's denote by $|S|$ the length of the string $S$ before the current operation. Each operation should be of one of the following types: - insert a lowercase English letter $x$ at the beginning of the string $S$; the cost of this operation is
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