[C++] Sliding window
This problem is extension of previous problem  Minimum Swaps to Group All 1\'s Together\nSo, I treat it in same way i treat previous problem using sliding windo
This problem is extension of previous problem  **[Minimum Swaps to Group All 1\'s Together](https://leetcode.com/problems/minimum-swaps-to-group-all-1s-together/)**\nSo, I treat it in same way i treat previous problem using sliding window.\n\nQ1. What must we find?\nAns. we must find portion in which the number of one is maximum.\n\nQ2. How to decide portion size? -> protion_size==window_size\nAns. Count number of one present in given array one.\n\t\tExample \n\t\t1 0 1 0 1\n\t\tHere size of window is 3.\n\nQ3. How to tackle circular constrain?\nAns. This is my favourite part most of time when I find this kind of statement, I prefer to append same array twice\uD83D\uDE05.\n\t Sorry for that it came with time you will find multiple question follow same approach.\n\n<iframe src="https://leetcode.com/playground/RuH79KjM/shared" frameBorder="0" width="800" height="600"></iframe>
[]