if (nodes[i] != nodes[i - 1])
if (!nodes[i].equals(nodes[i - 1]))
        int getTermCount() {            int count = 1;            for (int i = 1; i < position; i++) {                if (nodes[i] != nodes[i - 1])                    count++;            }            return count;        }