Skip to main content
Module

std/collections/mod.ts>BSTree.from

Deno standard library
Go to Latest
method BSTree.from
Re-export
import { BSTree } from "https://deno.land/std@0.145.0/collections/mod.ts";

Creates a new binary search tree from an array like or iterable object.

Parameters

collection: ArrayLike<T> | Iterable<T> | BSTree<T>

Parameters

collection: ArrayLike<T> | Iterable<T> | BSTree<T>
options: { compare?: (a: T, b: T) => number; }

Parameters

collection: ArrayLike<T> | Iterable<T> | BSTree<T>
options: { compare?: (a: U, b: U) => number; map: (value: T, index: number) => U; thisArg?: V; }

Parameters

collection: ArrayLike<T> | Iterable<T> | BSTree<T>
optional
options: { compare?: (a: U, b: U) => number; map?: (value: T, index: number) => U; thisArg?: V; }