kirancodes.me
To Proof Maintenance & Beyond!

916 papers · page 38 of 46

On Merging and Selection

Richard S. Bird

Given two ascending lists xs and ys of combined length greater than n, consider the computation offormula hereThe standard function merge merges two ascending sequences and (!!) denotes list indexing. With a lazy evaluator the computation takes O(n) steps; with an eager one it ta…