# Introduction

The Sliding window is a problem-solving technique of data structure and algorithm for problems that apply arrays or lists. These problems are painless to solve using a brute force approach in **O(n²)** or **O(n³)**. However, the **Sliding window** technique can reduce the time complexity to **O(n)**.

The basic idea behind…