← All problemsSign in

Junior_chef and Alice

Junior_chef and his classmates love a girl named Alice and want her to sit with them. But Alice, being a lover of Mathematics will only sit with the boy who can calculate the correct impressions of a problem. The problem goes like this - each student is given an identical string of length L. The impressions of a string is the number of such sub-sequences (http://en.wikipedia.org/wiki/Subsequence)

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start