Data Structures Lab4 (Java)