https://ide.codingblocks.com/#/s/30951
https://hack.codingblocks.com/contests/c/452/1665
String Window in hacker block
The question says to find a substring that contains all the characters of B, but you assumed that the order of characters in A is same as that in B.
For eg:
INPUT:
abcde
edc
OUTPUT:
No string
EXPECTED OUTPUT:
cde
Try correcting it by using count of each character of B and little of hashing
OR
Use two pointer method and keep a pointer at start and move the other pointer forward.
Here is my solution using first approach:
https://ide.codingblocks.com/#/s/31470
what is wrong in my code ? plz help