Fundamental Data Structures Lesson 2: Part 1

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/29

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 4:44 AM on 9/7/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

30 Terms

1
New cards

Array

A collection of items of same data type stored at contiguous memory locations

2
New cards

Array Index

In an array, elements are identified by their indexes.

3
New cards

Array Element

Items stored in an array and can be accessed by their index.

4
New cards

Array Length

The length of an array is determined by the number of elements it can contain.

5
New cards

One dimensional array, two dimensional array, three dimensional array

Enumerate the types of array

6
New cards

One dimensional array

A row, where elements are stored one after another.

7
New cards

Two dimensional array

Can be considered as an array of arrays or as a matrix consisting of rows and columns.

8
New cards

Three dimensional array

It can be considered an array of two-dimensional arrays.

9
New cards

traversal, insertion, searching, deletion, sorting

Enumerate the types of array operations

10
New cards

Linked List

A linear data structure, in which elements are not stored at a contiguous location, rather they are linked using pointers.

11
New cards

Node Structure

A node in a linked list typically consists of two components:

Data and Next pointer

12
New cards

Data

It holds the actual value associated with the node.

13
New cards

Next Pointer

It stores the memory address (reference) of the next node in the sequence.

14
New cards

Head and Tail

The linked list is accessed through the __ node, which points to the first node in the list. The last node in the list points to NULL or null pointer, indicating the end of the list. This node is known as the _ node.

15
New cards

Singly linked list, doubly linked list, circular linked list

Enumerate the types of linked list

16
New cards

Singly linked list

Each node contains a reference to the next node in the sequence. Traversing this linked list is done in a forward direction.

17
New cards

Doubly linked list

Each node contains references to both the next and previous nodes. This allows for traversal in both forward and backward directions, but it requires additional memory for the backward reference.

18
New cards

Circular linked list

The last node points back to the head node. It can be either singly or doubly linked.

19
New cards

insertion, deletion, searching and traversing

Enumerate the types of linked list operations

20
New cards

Dynamic size

Linked lists do not have a fixed size, so you can add or remove elements as needed, without having to worry about the size of the list. This makes linked lists a great choice when you need to work with a collection of items whose size can change dynamically.

21
New cards

Efficient Insertion and Deletion

Inserting or deleting elements in a linked list is fast and efficient, as you only need to modify the reference of the next node.

22
New cards

Memory Efficiency

Linked lists use only as much memory as they need, so they are more efficient with memory compared to arrays, which have a fixed size and can waste memory if not all elements are used.

23
New cards

Easy to Implement

Linked lists are relatively simple to implement and understand compared to other data structures like trees and graphs.

24
New cards

Flexibility

Linked lists can be used to implement various abstract data types, such as stacks, queues, and associative arrays.

25
New cards

Easy to navigate

Linked lists can be easily traversed, making it easier to find specific elements or perform operations on the list.

26
New cards

Slow access time

Accessing elements in a linked list can be slow, as you need to traverse the linked list to find the element you are looking for.

27
New cards

Pointers

Linked lists are more complex to understand and use compared to arrays. This complexity can make linked lists more difficult to debug and maintain.

28
New cards

Higher overhead

Linked list requires extra memory to store the reference to the next node.

29
New cards

Cache inefficiency

In linked lists the memory is not contiguous. This means that when you traverse a linked list, you are not likely to get the data you need in the cache, leading to cache misses and slow performance.

30
New cards

Extra memory required

Linked lists require an extra pointer for each node, which takes up extra memory.