PPT Slide
public void initializeTreeNode(int iNumberNodes) {
System.out.println (“Null tree found!”);
throw new NullPointerException (“Null tree found”);
/* NOTE: Runtime exception;
no need to declare propagation */
for (int i=0; i < iNumberNodes; i++) { {
TreeNode newNode = new TreeNode( i );
tree.insertNode(newNode);
When to Use Exceptions: Error with objects