site Search:


 
    All Forums Hot Topics Gallery






how-to block ads


 
Search Topic:
Uniqs:
1579
Share Topic
Post a:
Post a:
AuthorAll Replies


bigdip

@telus.net

putting a list into a binary search tree

can someone please help me make the following program in prolog. i need it to run as follows...

?- list2tree([7, 5, 1, 3, 6, 9] , T).

T = bt(7, bt(5, bt(1, nil, bt(3, nil, nil)), bt(6, nil, nil)), bt(9, nil, nil));

Monday, 20-May 22:22:48 Terms of Use & Privacy | feedback | contact | Hosting by nac.net - DSL,Hosting & Co-lo
over 13.5 years online © 1999-2013 dslreports.com.
Most commented news this week
Hot Topics