SYSC 2100 Lecture 5: Linked Lists

87 views3 pages

Document Summary

Data must be shifted during insertions and deletions. Is able to grow in size as needed. Does not require shifting of items during insertions and deletions. As a data field of a class has a default value of null. A reference variable local to a method does not have a default value (compiler error) When one reference variable is assigned to another reference variable, both references then refer to the same object. An object that is no longer accessible through any reference variable is marked for garbage collection. An array of objects is actually an array of references to the objects. == and != compares the values of the reference variable, not the objects that they reference. Redefine equals method compares objects field by field. When an object is passed to a method as an argument, the reference to the object is copied as a formal parameter. Reference - based adt implementations and data structures use java references.

Get access

Grade+
$40 USD/m
Billed monthly
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
10 Verified Answers
Class+
$30 USD/m
Billed monthly
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
7 Verified Answers

Related Documents