chickadee » sparse-vectors » sparse-vector-map

sparse-vector-map SPARSE-VECTOR FUNC #!optional SKIP?procedure

When SKIP? is #t unbound elements are skipped, otherwise the FUNC is treated to all elements; an implementation detail.

FUNC ; (INDEX VALUE -> T') ; element function.
T' ; defined-type ; type-of the SEED & ACC.
INDEX ; uinteger ; integer in [0 ...).
VALUE ; * ; but not DEFAULT.
SKIP? ; boolean ; skip unbound?

An O(n) operation, where n is total-count.