CS214_Fall2015_LN6_LinkedLists - CS 214 DATA STRUCTURES...

Info icon This preview shows pages 1–12. Sign up to view the full content.

View Full Document Right Arrow Icon
CS 214 DATA STRUCTURES FALL 2015 Lecture 6 Linked Lists November 9 th 2015 Group A & C Dr. Mai Hamdalla [email protected]
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
House Keeping Lab assessments Homework 1 & 2 grades Homework 3 Due this week in the lab Submit both hard and soft copy to TA Mid-term exam Next week (8 th week) Bring your ID and a photo copy of it to the exam. Linked LIsts 2
Image of page 2
Linked LIsts 3
Image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
LISTS Linked Lists 4
Image of page 4
What is a list? Linked LIsts 5 A number of connected items or names written or printed consecutively.
Image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
How are Lists Implemented? Arrays Linked Lists Linked LIsts 6
Image of page 6
List Implementation - Array 0x1000 317 0x1008 52 0x1010 122 0x1018 89 0x1180 0x1188 Linked LIsts 7 memory locations
Image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Arrays - Disadvantage I 0x1000 17 0x1008 52 0x1010 122 0x1018 289 0x1180 0x1188 Linked LIsts 8 memory locations 84 “Add element” is an expensive operation
Image of page 8
Arrays - Disadvantage II 0x1000 17 0x1008 52 0x1010 122 0x1018 289 290 0x1180 733 0x1188 756 Linked LIsts 9 memory locations 840 Fixed size! ??? If you allocate too much, it’s a waste of memory
Image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
LINKED LISTS Linked LIsts 10
Image of page 10
What is a linked list?
Image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 12
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern