Drzewo binarne PDF

Title Drzewo binarne
Author Rafał Olejniczak
Course Algorytmy I Struktury Danych I
Institution Uniwersytet Gdanski
Pages 15
File Size 60.3 KB
File Type PDF
Total Downloads 97
Total Views 131

Summary

Proste drzewo binarne...


Description

Proste drzewo binarne: #include #include //#include #include #include #include #include

using namespace std; int wybor; int *root; void clear() { #ifdef WIN32 system("cls"); #else system("clear"); #endif } //-------------------------------- Drzewo binarne zwykłe--------------------------------// void add(int dane[], bool space[] ,int n, int x) { if (space[1]==true) { root=&dane[1]; *root=x; space[1]=false; } else { bool found=false; int node=1; while (found==false) { if (space[node]==true) { found=true; dane[node]=x;

space[node]=false; } else if(xn) { cout...


Similar Free PDFs