if l==1 or 0, we just return it. Why do we do that? And what if same letter is present at l==0 and l==1. In this case why would we return the value?
String Remove Consecutive Duplicates
hello @yajurkhurana
here l is lenght of string.
if length is 1 or 0 then duplicates will not be there thats why we are returning for such cases
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.