public int numNodes(){
  if (m_Attribute == -1) {
    return 1;
  }
 else {
    int size=1;
    for (    Tree m_Successor : m_Successors) {
      size+=m_Successor.numNodes();
    }
    return size;
  }
}

public int numNodes ( ) { if ( m_Attribute == - 1 ) { return 1 ; } else { int size = 1 ; for ( Tree m_Successor : m_Successors ) { size += m_Successor . numNodes ( ) ; } return size ; } }
computes size of the tree .
