2 test cases not passed

@rachiitgupta your code is giving no giving correct output for test case like this
aaaabaaaa
your code is giving output
a8b1
but code should give
a4b1a4