You have a static array (no updates). You need to answer many range minimum queries: "what's the minimum element from index to ?" Segment trees give per query.
Can we do better? Sparse Tables achieve per query after preprocessing.
Here's the trick: for idempotent operations like and , overlapping ranges don't affect the answer.
Even though appears twice, the result is correct.
Sparse Tables exploit this by precomputing answers for ranges of power-of-2 lengths, then combining two overlapping ranges to answer any query. In this section, I'll teach you this powerful technique and when to apply it.