Skip to content

width / size [terminology]

Terminology

Usage

  • Use width for the width of merge-sort runs, matrix layers, or similar span-based units.
  • Use size for a general number of elements in a group.
  • Prefer run_size if several kinds of sizes coexist.
width = 1

while width < n:
    right = self._split_run(left, width)
    width *= 2