Data Structures19 sections · 729 units
Open in Course

Quiz: Prefix Sum Basics

Range query formula

Check Your Understanding

Given prefix sum array prefix[], what is the sum of elements from index 2 to 5 (inclusive)?

  1. A.prefix[5] - prefix[2]
  2. B.prefix[6] - prefix[1]
  3. C.prefix[5] - prefix[1]
  4. D.prefix[6] - prefix[2]
Start the roadmap to answer the quizzes and solve the challenges