Added Iterator class. Added findLeaves() function to tree. Added rule 5 code to optimizer. Needs testing.