Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/GAP/pkg/datastructures/tst/   (GAP Algebra Version 4.15.1©)  Datei vom 14.9.2025 mit Größe 492 B image not shown  

Quelle  binaryheap.tst  Sprache: unbekannt

 
Spracherkennung für: .tst vermutete Sprache: Lisp {Lisp[43] Masm[43] Apollo[34]} [Methode: maximale Elemente, drei Dimensionen]

gap> START_TEST("binaryheap.tst");
gap> ReadPackage("datastructures", "tst/heaptest.g");;

# run heap tests with binary heap constructor
gap> TestHeap(BinaryHeap);

#
# Test printing
#
gap> heap := BinaryHeap();
<binary heap with 0 entries>
gap> Push(heap, 1);
gap> heap;
<binary heap with 1 entries>

# Test invalid input
#gap> BinaryHeap(1);        # TODO
#gap> BinaryHeap(1, 1);     # TODO
gap> BinaryHeap(1, 1, 1);
Error, Wrong number of arguments

#
gap> STOP_TEST("binaryheap.tst", 1);

[Dauer der Verarbeitung: 0.2 Sekunden, vorverarbeitet 2026-10-20]