Documentation

Batteries.Data.List.ArrayMap

def List.toArrayMap {α : Type u} {β : Type v} (l : List α) (f : αβ) :

This function is provided as a more efficient runtime alternative to (l.map f).toArray. (It avoids the intermediate memory allocation of creating an intermediate list first.) For verification purposes, we immediately simplify it to that form.

Equations
    Instances For
      theorem List.toArrayMap_toList {α : Type u} {β : Type v} (l : List α) (f : αβ) :
      @[simp]
      theorem List.toArrayMap_eq_toArray_map {α : Type u} {β : Type v} (l : List α) (f : αβ) :