← All problemsSign in

Chef and Binary String

Chef provides you with a binary string 'S'. He can perform following operation any number of times on string 'S' ( including zero ). 1.) He can combine two consecutive '1' to form '0' 2.) He can combine two consecutive '0' to form '1' Help Chef to find the total number of strings he can form ? ###Input: - Input consist of single line String 'S'. ###Output: - Print a single l

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