binomial_heap: Create a new 'binomial_heap'

Description Usage Arguments Value Examples

View source: R/ds_heap_binomial.R

Description

Instantiates a new binomial_heap object, i.e. a tree-like data structure satisfying the min-heap property.

Usage

1
binomial_heap(key.class = c("character", "numeric", "integer"))

Arguments

key.class

the primitive class type of the keys

Value

returns a new binomial_heap object

Examples

1
2
3
4
5
6
7
8
 # creates a binomial_heap<character, SEXP>
 b_heap <- binomial_heap()

 # creates a binomial_heap<numeric, SEXP>
 b_heap <- binomial_heap("numeric")

 # creates a binomial_heap<character, SEXP>
 b_heap <- binomial_heap("character")

dirmeier/datastructures documentation built on Aug. 9, 2020, 2:55 a.m.