Implemented hashmap and equals functions in topic and book classes.