can I get a soon go this problem because I am unable to understand the editorial
Solution of this problem
here is my solution
you can take this as reference to understand https://ideone.com/SPsXY4
if you have some doubts in this feel free to ask doubt