Abstract AlgorithmsAbstract Algorithms

  • Home
  • All Posts
  • All Series
  • About

Category

sliding window

1 article

Sliding Window Technique: From O(n·k) Scans to O(n) in One Pass

Sliding Window Technique: From O(n·k) Scans to O(n) in One Pass

TLDR: Instead of recomputing a subarray aggregate from scratch on every shift, maintain it incrementally — add the incoming element, remove the outgoing element. For a fixed window this costs O(1) per

Mar 29, 2026•20 min read

Abstract Algorithms

Exploring the fascinating world of algorithms, data structures, and software engineering through clear explanations and practical examples.

Navigation

  • Home
  • All Posts
  • All Series
  • About

Series

  • How It Works: Internals Explained
  • System Design Interview Prep
  • Data Structures and Algorithms
  • LLM Engineering
  • Machine Learning Fundamentals

Popular Topics

  • data structures
  • algorithms
  • coding interview
  • Java
  • Heaps
  • caching

Author

Abstract Algorithms

Abstract Algorithms

@abstractalgorithms

1 followers on Hashnode

© 2026 Abstract Algorithms. All rights reserved.

Powered by Hashnode