Basic Explanation
\n/*\n    Using Monotonic Increasing Stack\n    \n    Example :  cdadabcc\n\t\n    Character Count : \n    c->3\n    d->2\n    a->2\n    b->1\n    \n\tIterating
```\n/*\n    Using Monotonic Increasing Stack\n    \n    Example :  cdadabcc\n\t\n    Character Count : \n    c->3\n    d->2\n    a->2\n    b->1\n    \n\tIterating to the given input string one by one : \n\t(Popping element from the stack only when element freq. is greater than one)\n\t\n   "c"  : c \n   "d"  : c d\n   "a"  : a\n    \n    c->2\n    d->1\n    a->2\n    b->1\n    \n    "d"  : a d\n    "a"  : this is already present in current stack\n    \n    c->2\n    d->1\n    a->1\n    b->1\n    \n    "b" : a d b\n    "c" : a d b c\n    "c" this already present in current stack\n        \n    c->1\n    d->1\n    a->1\n    b->1\n    \n    final stack ->  a d b c\n    \n*/\n```
[]