

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A concise review of key concepts related to data structures and uml diagrams, focusing on their application in computer science. It covers sequence diagrams, uml diagrams, maps, array lists, linked lists, sets, and hash codes. Examples and explanations relevant to understanding and implementing these concepts, making it a useful resource for students studying data structures and object-oriented design. It also touches on testing exceptions and the properties of different data structures, such as lists and sets, offering a quick reference for exam preparation or review. Useful for university students.
Typology: Exams
1 / 3
This page cannot be seen from the preview
Don't miss anything!


Sequence Diagram - correct answer One with lifelines and each object UML diagram - correct answer Tree-like representation of relationship between classes (check fields) then check body for associations Map - correct answer Map<key, value> newMapCreation = new HashMap<>; Adding something to a Map - correct answer this.BLANK.put(key,value); testing exceptions - correct answer Should leave blanks where the right thing is happening and include all the asserts after the try catch blocks Extends Arrow - correct answer straight arrow with open arrow head Implements Arrow - correct answer dotted with open arrow head Association arrow has a field of B - correct answer straight line normal arrow head with 1 Associate of a list of B - correct answer straight line normal arrow head with 0..* or 1...* depending on if list is initialized with one item or null Aggregation (A is a part of B ) - correct answer diamond at bottom of arrow
Array List fast at?? - correct answer add fast? add(i) slow get (I) fast remove (i) slow Linked List fast at?? - correct answer add fast add(i) slow get I slow remove I slow List properties - correct answer Keeps order and allows duplicates Set properties - correct answer Doesn't keep order Doesn't allow duplicates Hash Set Fast? - correct answer add e remove e printing keys - correct answer map.keySet(); getting value - correct answer map.get("key") overidinf hash code - correct answer @Overridepublic boolean equals(Object o) {if (this == o) return true; if (o == null || getClass() != o.getClass()) return