fenwick_range
Performs range updates and range sum queries on an array using a two-BIT Fenwick tree.
Instructions
Fenwick tree with range update and range query support using two BITs.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"values": "<values>",
"operations": "<operations>"
},
"name": "fenwick_range"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| values | Yes | Initial array values | |
| operations | Yes | Array of {type, left, right, value?} operations |