Chef And Salary Pay
Given the schedule of Chef for $30$ days (A binary string of length $30$ where `'0'` denotes that Chef was on leave and `'1'` denotes Chef was working on that day). Chef gets $X-$ Rs for every day he worked. As working continuously for a long time is hectic so Company introduced the following policy to give a bonus to its employees. The company will check the longest streak for which an employee
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