reset password
Author Message
LHS
Posts: 26
Posted 21:42 Dec 15, 2019 |

since the instructions say:

Implement a tree node type that has a student as one of its fields. The tree will be a binary search tree on the attribute age.

For python is there a way to force the tree node to use class student, or do we just insert student into it.

I know for Haskell you can declare what data types are allowed and which aren't for functions, I can't find anything in the python boot camp notes to do the same.(I know the instructions are copied and pasted from the Haskell homework so I am assuming it is worded with Haskell in mind.)

I am assuming we just insert the class object into the tree node since there is nothing in the notes to suggest another way.

 

duck10438
Posts: 36
Posted 00:54 Dec 16, 2019 |

https://csns.calstatela.edu/department/cs/forum/topic/view?id=7451094