Chef And Strings
CodeChefOpen on judge ↗
Chef has $N$ strings with him. He knows his strings very well. A very intelligent guy named Frank comes along and asked him a few questions about the strings. Chef is busy right now, so you have to help him answer the queries by Frank There are $Q$ queries each containing 3 integers $L , R, C$ and 1 character $P$. You are supposed to tell how many strings from $L$ to $R$ have the character $P$ at
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