: This message was edited by the STiAT at 2002-6-18 9:3:4
: This message was edited by the STiAT at 2002-6-18 8:56:44
: : Hi
: : i'm new to c# and would like to know how do i write a simple app
: : that will sort using binary tree a list with first & last name.
: : When i add a new name it will sort them
: : thanx
: : guy
: :
:
: Use classes like in C++. It's simple, you have a class for the tree, and one for the list of elements of the tree, and one for the elements of the list
:
: class list_element
: {
: private string fname, lname;
: private list_element next, back;
:
: //public ...
:
: }
:
: class tree_element
: {
: private list_element head;
: private tree_element left, right;
: //public ...
: }
:
: class btree
: {
: private tree_element root;
: //public all access functions...
: }
:
:
:
:
: