Startseite › Datentypen › H-Lib-Container Hilfe zum PBXB64-Compiler

H-Lib Heap (Priority Queue)

A binary min-heap storing LONG values. The smallest value is always returned by Pop.

Kategorie: H-Lib-Container | Zertifizierung: [ZERTIFIZIERT GETESTET]

Beschreibung

A binary min-heap storing LONG values. The smallest value is always returned by Pop.

Kind: Container | Category: H-Lib Native Containers

PBXB64 Status: AVAILABLE

PBXB64 Certification: [CERTIFIED TESTED]

Description

This H-Lib container is implemented in native C support code and exposed through PBXB64 BASIC container syntax. The examples below are focused usage patterns; keep handles valid, release each container with its Final method, and check counts or return values when a method can fail.

Methods

MethodSignatureReturnsDescription
Newh.NewLNHEAPAllocate a new empty heap.
Finalh.FinalnoneFree the heap.
Validateh.ValidateLONGNon-zero if the handle is valid.
Clearh.ClearnoneRemove all values.
Counth.CountLONGNumber of values in the heap.
Pushh.Push valuenoneInsert a LONG value.
Poph.PopQUADRemove and return the smallest value.
Peekh.PeekQUADReturn the smallest value without removing it.
Emptyh.EmptyLONGNon-zero if the heap is empty.

Validation Evidence

Validation evidence: H-Lib container behavior is exercised by registered BASIC container validation programs and the embedded H-Lib object set used by the single-EXE validation gate.

PBXB64-Prüfung

Diese Referenzseite soll durch ein fokussiertes Compile- oder Laufzeitbeispiel belegt sein. Das Beispiel soll Eingaben, erwartete Ausgabe oder Exit-Code und erforderliche Windows-Ressourcen oder Include-Dateien nennen.

Übersichtshinweise

Allgemeine Übersichtsseiten sollten trotzdem sagen, welche Familie gemeint ist, welche konkreten Befehlsseiten die Implementierung tragen und welche Formen nur der Navigation dienen. So bleibt die Seite detailliert genug, ohne so zu tun, als wäre sie eine vollständige Befehlsreferenz.

Beispiel

LOCAL h AS LNHEAP
h = h.New
h.Push 30
h.Push 10
h.Push 20
PRINT h.Pop   ' 10
PRINT h.Count ' 2
h.Final