8000 Clarify plurality of sums/ranges · cp-algorithms/cp-algorithms@34ebf06 · GitHub
[go: up one dir, main page]

Skip to content

Commit 34ebf06

Browse files
authored
Clarify plurality of sums/ranges
1 parent 195a1cd commit 34ebf06

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/data_structures/fenwick.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ The function `sum` works as follows:
7070

7171
The function `increase` works with the same analogy, but it "jumps" in the direction of increasing indices:
7272

73-
1. Sums of the range $[g(j), j]$ which satisfy the condition $g(j) \le i \le j$ are increased by `delta`; that is, `t[j] += delta`.
73+
1. The sum for each range of the form $[g(j), j]$ which satisfies the condition $g(j) \le i \le j$ is increased by `delta`; that is, `t[j] += delta`.
7474
Therefore, it updates all elements in $T$ that correspond to ranges in which $A_i$ lies.
7575

7676
The complexity of both `sum` and `increase` depend on the function $g$.

0 commit comments

Comments
 (0)
0