home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!destroyer!gumby!wmichgw!873clifton
- From: 873clifton@gw.wmich.edu
- Newsgroups: comp.lang.c
- Subject: Source for pointer based heapsort?
- Message-ID: <1992Nov6.165140.6197@gw.wmich.edu>
- Date: 6 Nov 92 16:51:40 EST
- Organization: Western Michigan University
- Lines: 26
-
- Hello fellow C programmers:
-
- Not having any luck searching: archie, usenet comp.sources groups,
- netlib, etc, I thought I might post a request for source hear. I
- am trying to implent heap building and heapsort using a struct
- pointer based method rather than the classic array based method.
- I searched every book on data structures/algorithms I could lay
- hands on as well as many programming periodicals, but all of them
- used the array based method. My proposed structure would look
- something like this:
-
- typedef struct _hnode {
- int data;
- struct _hnode *rchild; /* right child */
- struct _hnode *lchild; /* left child */
- ...
- } hnode;
-
- If some kind soul has solved this problem, could they please
- Email me their source.
-
- Thanks,
-
- /Doug
- --
- Douglas Clifton [99clifto@lab.cc.wmich.edu]
-