![]() |
.. (לתיקייה המכילה) | |
C++ part: There is an inconsistency between the reference Java program and the output specified in the assignment for printing tree2 in preorder. | |
The output specified in the assignment is correct. There is a bug in the Java reference program. The method print() of TreeUtils should be : public static void print(PrintStream outputStram, Tree t) { outputStram.println(t.value); print(outputStram, t.child, 1); } |
C++ Part: Are we allowed to add methods into the given structs such as Tree, List? | |
Yes, you are allowed (but not required) |
C++ Part: Can we assume that the trees are binary trees? | |
No. |
Swing part: Can a graph contain self loops? | |
Yes. In case of self loops, the direction column should display 'true'. |
C++ Part: may we assume that the tree given as argument to EdgesOf and PreOrder has no siblings (i.e., it is not a part of a forest)? | |
No, you may not assume this since any node in the tree which is not the root is a legal parameter to PreOrder. |
C++ part: should the output of EdgesListPrinter<...>::print be in the same order as in the output specified in the assignment? | |
No, the edges can be printed in any order. |
Swing part: When I use JOptionPane for creating the edges dialog, i get | |
It is ok, this is the behaviour of this dialog, when a small number of entries is added a combox box is displayed, otherwise a list is displayed. |
Swing part: what happens to the existing graph when we open a file ? | |
remove the old graph, and display the one read from the file |