Learning data structures and algorithms in java