Implement Prototype(values []int,commands []Command) ([]int,error) by copying and scanning; Solve uses a Fenwick tree. Command add uses A=index, B=delta; sum uses A=left, B=exclusive right. Return query results only in order; empty range returns zero. Signed values valid. Unknown op, invalid update index, or range failing 0<=left<=right<=n returns error. Preserve both inputs including on error. Addition is not replacement.
Edit exercise.go; retain the public types and signatures. prototype and final are separate stages. The executable tests recover panics as failures, report named checks, and exit nonzero on any failure. A successful run must execute at least one check. Tests use logical time or explicit synchronization where relevant.
Complete the starter code, then run the checks.
Results and errors will appear here.