adjacency matrix or 2-d array

darentan
darentan used Ask the Experts™
on
Hi all,

if writing in pas, would 2d array or adjacency matrix be better or easier.

i am preparing to write a program on subjects, objects and directed edges (like a b-tree) with checking for cycle.

and also is there any way we could write program to show the tree rather than sentences - eg.

                     a
                    / \
                   b   c
                  /\   /\
                 /  \ /  \
                /    \/   \
               d      e    f

Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Commented:
Hi,

Pascal is, on my opinion, the best choice for your project. But it is up to you what language to use. You can solve your project using C++, or for example Eiffel.

With regard to Pascal You can find lots of sources in the internet. Below I you can see some of them.

http://www.geocities.com/SiliconValley/Park/3230/pas/pasl1006.html
http://www.nist.gov/dads/HTML/btree.html

I hope it could be helpfull.

Regards,
SVik

Author

Commented:
i thinking of gui interface as in java as pas are bad in it. it is my assignment and only two choice - java or pas. but java i not so sure :(

the tricky part is the displaying of the adjacency maxtrix into tree figure rather than table .
Commented:
I don"t know what platform you plan to use. In Windows you can use Delphi (comercial) or some free compilers for example
freepascal (www.freepascal.org) or you can find something another (http://www.thefreecountry.com/developercity/pascal.shtml)
In Linux you can use free Delphi port - Kylix.

With regard to Java it is free too.
On my opinion the best language is that one which you know :).

Regards,
SVik
darentan:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial