Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Tree heap ( int a[], int n ){
- Tree new = NULL;
- heapaux ( int a, n, int i=0, new );
- return new;
- }
- void heapaux ( int a[], int n, int i, Tree new ){
- int esq, dir;
- if(i<n){
- insere(i,new);
- heapaux(a, n, esq=LEFT(i), new);
- heapaux(a, n, dir=RIGHT(i), new);
- }
- }
Add Comment
Please, Sign In to add comment