I am still not able to understand 2 pointer approach?how should i iterate over string? and why is initial value of j is k?please send me the complete solution!

i am still not able to understand 2 pointer approach??how should i iterate over string? and why is initial value of j is k?please send me the complete solution !!

@shakul
I cannot provide with the complete solution of this problem as that would defy the purpose of learning.
Two pointer approach says you need to keep two variables i and j which slide across the string. The window created by these variable i and j is the window under current observation.
i makes the left end of the window while j marks the right end of the window.
We initialise i from 0 and j from k as the smallest size of our window will atleast be k.
As for iterating over the string , use a simple for or a while loop.