CSC403: More Size: How is this different? [2/10] |
public class IntSet { private Node root; private static class Node { public final int key; public Node left, right; public Node (int key) { this.key = key; } } int size = 0; public int size () { for (int x : this.levelOrder ()) size++; return size; } ...
This now violates yet another criterion of the assignment.
A field is a variable that is declared outside of a method.