http://ide.codingblocks.com/#/s/13014
Sir when I try to run this code in hacker blocks, I don’t pass two test cases.
https://hack.codingblocks.com/contests/c/474/1371
This is the link for the question.
http://ide.codingblocks.com/#/s/13014
Sir when I try to run this code in hacker blocks, I don’t pass two test cases.
https://hack.codingblocks.com/contests/c/474/1371
This is the link for the question.
Hi,
I am one of the moderators.
You have not mapped the counter of a character using the ascii value, also if a character is not repeated contiguously and occurs only once then count should not be included in answer.
e.g., if input is “aaabcdd” then output must be “a3bcd2”
What will be the condition or logic for it?
You are using ‘c’ for counting the no of contiguous characters, you can write logic on your own.
And ‘0’ is mapped to ascii value 48. But, if c is 0 then you are mapping it to 49.
I have modified your code and commented on line no.s where your code had errors
https://ide.codingblocks.com/#/s/13906