haskell - Is there a aggregation version of Sequences exists already? -


consider have sequence of monoid elements, data.sequence great inserting, changing elements in positions.

i'm concerned following query, sum j sequence, returns mconcat of elements position i j. can done using fingertree measure contain both index , mconcat result in o(log n) time.

is there implementation of in haskell library? or have implement data.sequence again ability data.fingertree? (sequence expose little internal structure effectively.)


Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

.htaccess - Matching full URL in RewriteCond -